Check for a behavior change with URL pattern mapping

The URL pattern mapping behavior is different in the Servlet 3.1 feature implementation than in the Servlet 3.0 implementation. In Servlet 3.0, an application can start successfully even if the same URL pattern is mapped to multiple servlets. In Servlet 3.1, the application does not start and throws the following exception:

SRVE9016E: Unable to insert mapping [{0}] for servlet named [{1}]. The URL pattern is already defined for servlet named [{2}].

To resolve this error, update the application URL patterns so that each URL pattern is mapped to a single servlet.

This rule flags URL patterns that are mapped to multiple servlets. URL patterns are specified in the following locations:

For more information on Servlet 3.1 behavior changes, see the following resource: Servlet 3.1 behavior changes.