You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tomcat.apache.org by ma...@apache.org on 2026/08/10 21:06:45 UTC

(tomcat) 01/02: Make URL and URL-pattern decoding configurable.

This is an automated email from the ASF dual-hosted git repository.

markt-asf pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/tomcat.git

commit db8ddf7ccda071437136ea5f5f1e87d67ed61604
Author: Mark Thomas <ma...@apache.org>
AuthorDate: Mon Aug 10 20:44:10 2026 +0100

    Make URL and URL-pattern decoding configurable.
    
    The Servlet specification states URLs and URL patterns should always be
    specified in URL-decoded form. However, the Tomcat commit logs from the
    time (more than quarter of a century ago) suggests the exact opposite
    was intended:
    https://lists.apache.org/thread/fzcq06b7dl8w3q8j1jhvq9cmbsq5f2f3
    
    This commit does not change the default behaviour of URL-decoding URLs
    and URL patterns (it will change for 12.0.x once this change has been
    back-ported).
    
    In the unlikely event an application needs to specify a URL or URL
    pattern that needs to be URL-decoded, the configuration options allows
    the application to migrate when they are ready.
---
 java/org/apache/catalina/Context.java              |  80 ++++++++++++++++-
 .../core/ApplicationFilterRegistration.java        |   9 +-
 .../core/ApplicationServletRegistration.java       |   9 +-
 java/org/apache/catalina/core/StandardContext.java |  34 ++++++-
 .../org/apache/catalina/startup/ContextConfig.java |  22 +++--
 .../org/apache/catalina/startup/FailedContext.java |   6 ++
 java/org/apache/catalina/startup/Tomcat.java       |   6 +-
 .../tomcat/util/descriptor/web/ErrorPage.java      |   4 +
 .../tomcat/util/descriptor/web/FilterMap.java      |   4 +
 .../descriptor/web/FragmentJarScannerCallback.java |   6 +-
 .../util/descriptor/web/JspPropertyGroup.java      |   3 +
 .../tomcat/util/descriptor/web/LoginConfig.java    |   7 ++
 .../util/descriptor/web/SecurityCollection.java    |   4 +
 .../util/descriptor/web/SecurityConstraint.java    |   1 +
 .../tomcat/util/descriptor/web/WebRuleSet.java     |  61 +++++++++++--
 .../apache/tomcat/util/descriptor/web/WebXml.java  |  65 +++++++++++---
 .../tomcat/util/descriptor/web/WebXmlParser.java   |  47 ++++++++--
 .../util/descriptor/web/XmlEncodingBase.java       |  11 ++-
 .../servlet/TestServletRequestParameters.java      |   2 +-
 ...TestServletRequestParametersFormUrlEncoded.java |   2 +-
 ...stServletRequestParametersMultipartEncoded.java |   2 +-
 .../TestServletRequestParametersQueryString.java   |   2 +-
 .../servlet/annotation/TestServletSecurity.java    |   4 +-
 .../servlet/http/HttpServletDoHeadBaseTest.java    |   4 +-
 test/jakarta/servlet/http/TestHttpServlet.java     |  20 ++---
 .../http/TestHttpServletResponseSendError.java     |   8 +-
 .../authenticator/TestAuthInfoResponseHeaders.java |   4 +-
 .../TestAuthenticatorBaseCorsPreflight.java        |   6 +-
 .../authenticator/TestDigestAuthenticator.java     |   4 +-
 .../TestDigestAuthenticatorAlgorithms.java         |   4 +-
 .../authenticator/TestDigestAuthenticatorB.java    |   4 +-
 .../authenticator/TestFormAuthenticatorA.java      |   6 +-
 .../TestNonLoginAndBasicAuthenticator.java         |  16 ++--
 .../authenticator/TestSSOChangeSessionId.java      |   8 +-
 .../TestSSOnonLoginAndBasicAuthenticator.java      |  16 ++--
 .../TestSSOnonLoginAndDigestAuthenticator.java     |  12 +--
 .../catalina/connector/TestClientReadTimeout.java  |   2 +-
 .../apache/catalina/connector/TestConnector.java   |   6 +-
 .../catalina/connector/TestCoyoteAdapter.java      |  10 +--
 .../TestCoyoteAdapterCanonicalization.java         |   2 +-
 .../connector/TestCoyoteAdapterRequestFuzzing.java |   2 +-
 .../catalina/connector/TestCoyoteInputStream.java  |   2 +-
 .../catalina/connector/TestCoyoteOutputStream.java |   8 +-
 .../apache/catalina/connector/TestInputBuffer.java |   6 +-
 .../catalina/connector/TestKeepAliveCount.java     |   2 +-
 .../catalina/connector/TestMaxConnections.java     |   2 +-
 .../catalina/connector/TestOutputBuffer.java       |   6 +-
 .../org/apache/catalina/connector/TestRequest.java |  24 ++---
 .../apache/catalina/connector/TestResponse.java    |   8 +-
 .../apache/catalina/connector/TestSendFile.java    |   4 +-
 .../connector/TestValidateClientSessionId.java     |   6 +-
 .../catalina/core/TestApplicationContext.java      |   6 +-
 ...TestApplicationContextGetRequestDispatcher.java |   6 +-
 ...estApplicationContextGetRequestDispatcherB.java |   4 +-
 ...estApplicationContextGetRequestDispatcherC.java |   4 +-
 .../catalina/core/TestApplicationDispatcher.java   |   6 +-
 .../catalina/core/TestApplicationFilterConfig.java |   2 +-
 .../catalina/core/TestApplicationHttpRequest.java  |   8 +-
 .../catalina/core/TestApplicationMapping.java      |  22 ++---
 .../apache/catalina/core/TestAsyncContextImpl.java | 100 ++++++++++-----------
 .../core/TestAsyncContextImplDispatch.java         |   4 +-
 .../TestAsyncContextImplListenerOnComplete.java    |   2 +-
 .../catalina/core/TestAsyncContextIoError.java     |   4 +-
 .../core/TestAsyncContextStateChanges.java         |   2 +-
 .../core/TestPropertiesRoleMappingListener.java    |   2 +-
 .../apache/catalina/core/TestStandardContext.java  |   8 +-
 .../catalina/core/TestStandardContextAliases.java  |   2 +-
 .../core/TestStandardContextResources.java         |   6 +-
 .../catalina/core/TestStandardContextValve.java    |   8 +-
 .../catalina/core/TestStandardHostValve.java       |  10 +--
 .../apache/catalina/core/TestStandardWrapper.java  |   4 +-
 .../catalina/core/TestSwallowAbortedUploads.java   |   4 +-
 .../catalina/filters/TestAddCharSetFilter.java     |   2 +-
 .../apache/catalina/filters/TestExpiresFilter.java |   8 +-
 .../catalina/filters/TestRateLimitFilter.java      |   2 +-
 .../TestRateLimitFilterWithExactRateLimiter.java   |   2 +-
 .../catalina/filters/TestRemoteCIDRFilter.java     |   2 +-
 .../catalina/filters/TestRemoteIpFilter.java       |  10 +--
 .../filters/TestRestCsrfPreventionFilter2.java     |   6 +-
 .../catalina/ha/context/TestReplicatedContext.java |   2 +-
 .../TestWebappClassLoaderExecutorMemoryLeak.java   |   2 +-
 .../loader/TestWebappClassLoaderMemoryLeak.java    |   2 +-
 ...sterWebappClassLoaderThreadLocalMemoryLeak.java |   4 +-
 .../catalina/manager/TestHostManagerWebapp.java    |   2 +-
 .../apache/catalina/manager/TestManagerWebapp.java |   2 +-
 .../catalina/manager/TestStatusTransformer.java    |   6 +-
 .../apache/catalina/mapper/TestMapperWebapps.java  |   6 +-
 .../catalina/nonblocking/TestNonBlockingAPI.java   |  22 ++---
 test/org/apache/catalina/realm/TestRealmBase.java  |  10 +--
 .../servlets/DefaultServletEncodingBaseTest.java   |   4 +-
 .../catalina/servlets/ServletOptionsBaseTest.java  |   2 +-
 .../catalina/servlets/TestDefaultServlet.java      |  24 ++---
 .../TestDefaultServletIfMatchRequests.java         |   2 +-
 .../catalina/servlets/TestDefaultServletPut.java   |   2 +-
 .../servlets/TestDefaultServletRangeRequests.java  |   2 +-
 .../TestDefaultServletRfc9110Section13.java        |   2 +-
 .../TestDefaultServletRfc9110Section14.java        |   4 +-
 .../catalina/servlets/TestWebdavServlet.java       |  22 ++---
 .../TestPersistentManagerDataSourceStore.java      |   2 +-
 .../session/TestPersistentManagerFileStore.java    |   2 +-
 .../session/TestPersistentManagerIntegration.java  |   6 +-
 .../session/TestStandardSessionAccessor.java       |   2 +-
 .../session/TestStandardSessionIntegration.java    |   2 +-
 .../org/apache/catalina/ssi/TestRegExpCapture.java |   2 +-
 test/org/apache/catalina/ssi/TestSsiServlet.java   |   4 +-
 .../apache/catalina/startup/EmbeddedTomcat.java    |   2 +-
 .../apache/catalina/startup/TestContextConfig.java |   4 +-
 .../startup/TestContextConfigAnnotation.java       |   2 +-
 .../catalina/startup/TestPropertySources.java      |   2 +-
 .../startup/TestStartupIPv6Connectors.java         |   2 +-
 test/org/apache/catalina/startup/TestTomcat.java   |  12 +--
 .../catalina/startup/TestTomcatClassLoader.java    |   4 +-
 .../catalina/startup/TestTomcatStandalone.java     |   2 +-
 .../apache/catalina/valves/TestAccessLogValve.java |   2 +-
 .../catalina/valves/TestAccessLogValveFile.java    |   2 +-
 .../catalina/valves/TestErrorReportValve.java      |  14 +--
 .../valves/TestExtendedAccessLogValve.java         |   2 +-
 .../apache/catalina/valves/TestFilterValve.java    |   6 +-
 .../catalina/valves/TestJsonErrorReportValve.java  |  24 ++---
 .../catalina/valves/TestParameterLimitValve.java   |  36 ++++----
 .../catalina/valves/TestPersistentValveAsync.java  |  10 +--
 .../catalina/valves/TestProxyErrorReportValve.java |  24 ++---
 .../apache/catalina/valves/TestSemaphoreValve.java |  16 ++--
 .../catalina/valves/rewrite/TestRewriteValve.java  |  20 ++---
 .../webresources/TestWebResourceContentType.java   |   2 +-
 test/org/apache/coyote/TestAbstractProtocol.java   |   2 +-
 test/org/apache/coyote/TestIoTimeouts.java         |   2 +-
 test/org/apache/coyote/TestResponse.java           |   4 +-
 .../coyote/ajp/TestAbstractAjpProcessor.java       |  16 ++--
 .../coyote/http11/TestHttp11InputBuffer.java       |  10 +--
 .../coyote/http11/TestHttp11InputBufferCRLF.java   |   2 +-
 .../coyote/http11/TestHttp11OutputBuffer.java      |   4 +-
 .../apache/coyote/http11/TestHttp11Processor.java  |  70 +++++++--------
 .../coyote/http11/TestHttp11ProcessorDoHead.java   |   2 +-
 .../http11/filters/TestChunkedInputFilter.java     |  26 +++---
 .../apache/coyote/http11/upgrade/TestUpgrade.java  |   2 +-
 .../http11/upgrade/TestUpgradeInternalHandler.java |   2 +-
 test/org/apache/coyote/http2/Http2TestBase.java    |  10 +--
 test/org/apache/coyote/http2/TestAsync.java        |   4 +-
 test/org/apache/coyote/http2/TestAsyncError.java   |   4 +-
 test/org/apache/coyote/http2/TestAsyncFlush.java   |   4 +-
 .../apache/coyote/http2/TestAsyncReadListener.java |   4 +-
 test/org/apache/coyote/http2/TestAsyncTimeout.java |   4 +-
 .../apache/coyote/http2/TestCancelledUpload.java   |   2 +-
 .../apache/coyote/http2/TestHttp2AccessLogs.java   |   4 +-
 .../coyote/http2/TestHttp2UpgradeHandler.java      |   8 +-
 test/org/apache/coyote/http2/TestLargeUpload.java  |   2 +-
 .../http2/TestStandardSessionIntegrationHttp2.java |   4 +-
 test/org/apache/coyote/http2/TestStream.java       |   8 +-
 .../apache/coyote/http2/TestStreamProcessor.java   |  44 ++++-----
 .../apache/coyote/http2/TestStreamQueryString.java |   2 +-
 .../apache/jasper/runtime/TestPageContextImpl.java |   2 +-
 test/org/apache/jasper/servlet/TestJspServlet.java |   2 +-
 .../apache/juli/TestPerWebappJuliIntegration.java  |   4 +-
 test/org/apache/naming/TestEnvEntry.java           |   2 +-
 .../apache/naming/resources/TestNamingContext.java |  10 +--
 .../httpd/HttpdIntegrationBaseTest.java            |   2 +-
 .../integration/httpd/TestErrorHandling.java       |   2 +-
 .../tomcat/security/TestSecurity2017Ocsp.java      |   2 +-
 .../apache/tomcat/security/TestSecurity2018.java   |   2 +-
 .../apache/tomcat/security/TestSecurity2019.java   |   8 +-
 .../apache/tomcat/security/TestSecurity2023.java   |   8 +-
 test/org/apache/tomcat/unittest/TesterContext.java |   7 ++
 .../web/TestJspPropertyGroupDescriptorImpl.java    |   2 +-
 .../descriptor/web/TestSecurityConstraint.java     |   8 +-
 .../tomcat/util/descriptor/web/TestWebXml.java     |   5 +-
 .../apache/tomcat/util/http/TestCookieParsing.java |   2 +-
 .../http/TestCookieProcessorGenerationHttp.java    |   4 +-
 .../util/http/TestMimeHeadersIntegration.java      |   2 +-
 .../apache/tomcat/util/net/TestAlpnFallback.java   |   2 +-
 .../tomcat/util/net/TestLargeClientHello.java      |   2 +-
 test/org/apache/tomcat/util/net/TestPQC.java       |   2 +-
 .../tomcat/util/net/TestSSLHostConfigCipher.java   |   2 +-
 .../tomcat/util/net/TestSSLHostConfigCompat.java   |   2 +-
 .../tomcat/util/net/TestSSLHostConfigProtocol.java |   4 +-
 test/org/apache/tomcat/util/net/TestSsl.java       |   6 +-
 .../tomcat/util/net/TestSslHandshakeFailure.java   |   2 +-
 test/org/apache/tomcat/util/net/TesterSupport.java |   6 +-
 .../apache/tomcat/util/net/ocsp/OcspBaseTest.java  |   2 +-
 .../tomcat/util/net/ocsp/TesterOcspResponder.java  |   2 +-
 .../tomcat/websocket/TestWebSocketFrameClient.java |  14 +--
 .../websocket/TestWebSocketFrameClientSSL.java     |   4 +-
 .../tomcat/websocket/TestWsPingPongMessages.java   |   2 +-
 .../tomcat/websocket/TestWsRemoteEndpoint.java     |   4 +-
 .../websocket/TestWsSessionSuspendResume.java      |   4 +-
 .../tomcat/websocket/TestWsSubprotocols.java       |   2 +-
 .../tomcat/websocket/TestWsWebSocketContainer.java |  14 +--
 .../TestWsWebSocketContainerGetOpenSessions.java   |   2 +-
 .../websocket/TestWsWebSocketContainerSSL.java     |   2 +-
 ...ocketContainerSessionExpiryContainerClient.java |   2 +-
 ...ocketContainerSessionExpiryContainerServer.java |   2 +-
 ...stWsWebSocketContainerSessionExpirySession.java |   2 +-
 .../TestWsWebSocketContainerTimeoutClient.java     |   2 +-
 .../TestWsWebSocketContainerTimeoutServer.java     |   2 +-
 .../TesterConnectionLimitPerformance.java          |   2 +-
 .../websocket/TesterWebSocketClientProxy.java      |   4 +-
 .../apache/tomcat/websocket/WebSocketBaseTest.java |   2 +-
 .../websocket/pojo/TestEncodingDecoding.java       |  12 +--
 .../websocket/pojo/TestPojoEndpointBase.java       |   4 +-
 .../websocket/pojo/TestPojoMethodMapping.java      |   2 +-
 .../server/TestAsyncMessagesPerformance.java       |   2 +-
 .../tomcat/websocket/server/TestClassLoader.java   |   2 +-
 .../tomcat/websocket/server/TestCloseBug58624.java |   2 +-
 .../tomcat/websocket/server/TestShutdown.java      |   2 +-
 .../tomcat/websocket/server/TestSlowClient.java    |   2 +-
 .../TestWsRemoteEndpointImplServerDeadlock.java    |   2 +-
 .../websocket/server/TestWsServerContainer.java    |   4 +-
 .../server/TesterWsRemoteEndpointImplServer.java   |   2 +-
 webapps/docs/changelog.xml                         |  14 +++
 webapps/docs/config/context.xml                    |  16 ++++
 210 files changed, 988 insertions(+), 665 deletions(-)

diff --git a/java/org/apache/catalina/Context.java b/java/org/apache/catalina/Context.java
index 809f83a009..1f8a96740b 100644
--- a/java/org/apache/catalina/Context.java
+++ b/java/org/apache/catalina/Context.java
@@ -905,10 +905,45 @@ public interface Context extends Container, ContextBind {
 
     /**
      * Add a new servlet mapping, replacing any existing mapping for the specified pattern.
+     * <p>
+     * No URL-decoding of the pattern will be performed.
+     *
+     * @param pattern URL pattern to be mapped
+     * @param name    Name of the corresponding servlet to execute
+     */
+    default void addServletMapping(String pattern, String name) {
+        addServletMapping(pattern, name, false);
+    }
+
+
+    /**
+     * Add a new servlet mapping, replacing any existing mapping for the specified pattern.
+     * <p>
+     * No URL-decoding of the pattern will be performed.
+     * <p>
+     * Implementation Note: As of Tomcat 12 this default implementation will be removed. Implementors are encouraged to
+     * provide their own implementation of this method before then.
+     *
+     * @param pattern     URL pattern to be mapped
+     * @param name        Name of the corresponding servlet to execute
+     * @param jspWildcard true if name identifies the JspServlet and pattern contains a wildcard; false otherwise
+     */
+    default void addServletMapping(String pattern, String name, boolean jspWildcard) {
+        addServletMappingDecoded(pattern, name, jspWildcard);
+    }
+
+
+    /**
+     * Add a new servlet mapping, replacing any existing mapping for the specified pattern.
+     * <p>
+     * No URL-decoding of the pattern will be performed.
      *
      * @param pattern URL pattern to be mapped
      * @param name    Name of the corresponding servlet to execute
+     *
+     * @deprecated Will be removed in Tomcat 12 onwards.
      */
+    @Deprecated
     default void addServletMappingDecoded(String pattern, String name) {
         addServletMappingDecoded(pattern, name, false);
     }
@@ -916,11 +951,21 @@ public interface Context extends Container, ContextBind {
 
     /**
      * Add a new servlet mapping, replacing any existing mapping for the specified pattern.
+     * <p>
+     * No URL-decoding of the pattern will be performed.
      *
      * @param pattern     URL pattern to be mapped
      * @param name        Name of the corresponding servlet to execute
      * @param jspWildcard true if name identifies the JspServlet and pattern contains a wildcard; false otherwise
+     *
+     * @deprecated This method will be removed in Tomcat 12. Implementors are expected to implement this method without
+     *                 delegating the implementation to one of the other {@code addServletMapping*} methods as that may
+     *                 trigger infinite loops. Once this method has been removed from the interface, implementors may
+     *                 wish to move their implementation of this method to
+     *                 {@link Context#addServletMapping(String, String, boolean)} and remove their implementation of
+     *                 this method.
      */
+    @Deprecated
     void addServletMappingDecoded(String pattern, String name, boolean jspWildcard);
 
 
@@ -1184,8 +1229,7 @@ public interface Context extends Container, ContextBind {
     /**
      * Returns the array of welcome files defined for this Context.
      *
-     * @return the array of welcome files defined for this Context. If none are defined, a zero-length array is
-     *             returned
+     * @return the array of welcome files defined for this Context. If none are defined, a zero-length array is returned
      */
     String[] findWelcomeFiles();
 
@@ -2046,4 +2090,36 @@ public interface Context extends Container, ContextBind {
     default EncodedSolidusHandling getEncodedSolidusHandlingEnum() {
         return EncodedSolidusHandling.REJECT;
     }
+
+
+    /**
+     * Configures whether the Context expects URLs and URL patterns provided in web.xml, annotations and their
+     * programmatic equivalents to be in URL-decoded form.
+     *
+     * @param urlPatternsProvidedInDecodedForm {@code true} if URLs and URL patterns are expected to be decoded.
+     *                                             {@code false} if they are expected to be URL-encoded (i.e.
+     *                                             {@code %nn} encoding)
+     *
+     * @deprecated This is a transitional setting that will be removed in Tomcat 12 where it will be hard-coded to
+     *                 {@code true}
+     */
+    @Deprecated
+    default void setUrlPatternsProvidedInDecodedForm(boolean urlPatternsProvidedInDecodedForm) {
+        throw new UnsupportedOperationException();
+    }
+
+
+    /**
+     * Does this Context expect URLs and URL patterns provided in web.xml, annotations and their programmatic
+     * equivalents to be in URL-decoded form?
+     *
+     * @return This default implementation returns {@code false}
+     *
+     * @deprecated This is a transitional setting that will be removed in Tomcat 12 where it will be hard-coded to
+     *                 {@code true}
+     */
+    @Deprecated
+    default boolean getUrlPatternsProvidedInDecodedForm() {
+        return false;
+    }
 }
diff --git a/java/org/apache/catalina/core/ApplicationFilterRegistration.java b/java/org/apache/catalina/core/ApplicationFilterRegistration.java
index 29aeae0ec5..d824574ca8 100644
--- a/java/org/apache/catalina/core/ApplicationFilterRegistration.java
+++ b/java/org/apache/catalina/core/ApplicationFilterRegistration.java
@@ -89,6 +89,7 @@ public class ApplicationFilterRegistration implements FilterRegistration.Dynamic
         }
     }
 
+    @SuppressWarnings("deprecation")
     @Override
     public void addMappingForUrlPatterns(EnumSet<DispatcherType> dispatcherTypes, boolean isMatchAfter,
             String... urlPatterns) {
@@ -108,8 +109,12 @@ public class ApplicationFilterRegistration implements FilterRegistration.Dynamic
                 if (urlPattern == null) {
                     throw new IllegalArgumentException(sm.getString("applicationFilterRegistration.nullUrlPattern"));
                 }
-                // URL decoded using UTF-8 in addURLPattern
-                filterMap.addURLPattern(urlPattern);
+                if (context.getUrlPatternsProvidedInDecodedForm()) {
+                    filterMap.addURLPatternDecoded(urlPattern);
+                } else {
+                    // % decoded (if required) using UTF-8
+                    filterMap.addURLPattern(urlPattern);
+                }
             }
 
             if (isMatchAfter) {
diff --git a/java/org/apache/catalina/core/ApplicationServletRegistration.java b/java/org/apache/catalina/core/ApplicationServletRegistration.java
index 93a2c47506..981ce6f50e 100644
--- a/java/org/apache/catalina/core/ApplicationServletRegistration.java
+++ b/java/org/apache/catalina/core/ApplicationServletRegistration.java
@@ -167,6 +167,7 @@ public class ApplicationServletRegistration implements ServletRegistration.Dynam
     }
 
 
+    @SuppressWarnings("deprecation")
     @Override
     public Set<String> addMapping(String... urlPatterns) {
         if (urlPatterns == null) {
@@ -178,7 +179,11 @@ public class ApplicationServletRegistration implements ServletRegistration.Dynam
             if (urlPatterns[i] == null) {
                 throw new IllegalArgumentException(sm.getString("applicationServletRegistration.nullUrlPattern"));
             }
-            decodedUrlPatterns[i] = UDecoder.URLDecode(urlPatterns[i], StandardCharsets.UTF_8);
+            if (context.getUrlPatternsProvidedInDecodedForm()) {
+                decodedUrlPatterns[i] = urlPatterns[i];
+            } else {
+                decodedUrlPatterns[i] = UDecoder.URLDecode(urlPatterns[i], StandardCharsets.UTF_8);
+            }
         }
 
         Set<String> conflicts = new HashSet<>();
@@ -210,7 +215,7 @@ public class ApplicationServletRegistration implements ServletRegistration.Dynam
         overrides.forEach(p -> context.removeServletMapping(p));
 
         for (String urlPattern : decodedUrlPatterns) {
-            context.addServletMappingDecoded(urlPattern, wrapper.getName());
+            context.addServletMapping(urlPattern, wrapper.getName());
         }
 
         if (constraint != null) {
diff --git a/java/org/apache/catalina/core/StandardContext.java b/java/org/apache/catalina/core/StandardContext.java
index 8d0471421f..bce91cf716 100644
--- a/java/org/apache/catalina/core/StandardContext.java
+++ b/java/org/apache/catalina/core/StandardContext.java
@@ -810,9 +810,29 @@ public class StandardContext extends ContainerBase implements Context, Notificat
 
     private EncodedSolidusHandling encodedSolidusHandling = EncodedSolidusHandling.REJECT;
 
+    // Defaults to false for backwards compatibility but will be hard-coded to true for Tomcat 12 onwards.
+    private boolean urlPatternsProvidedInDecodedForm = false;
+
 
     // ----------------------------------------------------- Context Properties
 
+    @Override
+    public void setUrlPatternsProvidedInDecodedForm(boolean urlPatternsProvidedInDecodedForm) {
+        this.urlPatternsProvidedInDecodedForm = urlPatternsProvidedInDecodedForm;
+    }
+
+
+    /**
+     * {@inheritDoc}
+     *
+     * @return {@code true} if URLs and URL patterns are expected in URL-decoded form, otherwise {@code false}
+     */
+    @Override
+    public boolean getUrlPatternsProvidedInDecodedForm() {
+        return urlPatternsProvidedInDecodedForm;
+    }
+
+
     @Override
     public String getEncodedReverseSolidusHandling() {
         return encodedReverseSolidusHandling.getValue();
@@ -1992,6 +2012,7 @@ public class StandardContext extends ContainerBase implements Context, Notificat
     }
 
 
+    @SuppressWarnings("deprecation")
     @Override
     public void setLoginConfig(LoginConfig config) {
 
@@ -2005,6 +2026,7 @@ public class StandardContext extends ContainerBase implements Context, Notificat
                 if (log.isDebugEnabled()) {
                     log.debug(sm.getString("standardContext.loginConfig.loginWarning", loginPage));
                 }
+                // Use decoded variant to avoid double decoding
                 config.setLoginPageDecoded("/" + loginPage);
             } else {
                 throw new IllegalArgumentException(sm.getString("standardContext.loginConfig.loginPage", loginPage));
@@ -2016,6 +2038,7 @@ public class StandardContext extends ContainerBase implements Context, Notificat
                 if (log.isDebugEnabled()) {
                     log.debug(sm.getString("standardContext.loginConfig.errorWarning", errorPage));
                 }
+                // Use decoded variant to avoid double decoding
                 config.setErrorPageDecoded("/" + errorPage);
             } else {
                 throw new IllegalArgumentException(sm.getString("standardContext.loginConfig.errorPage", errorPage));
@@ -2815,7 +2838,7 @@ public class StandardContext extends ContainerBase implements Context, Notificat
              */
             String[] jspMappings = oldJspServlet.findMappings();
             for (int i = 0; jspMappings != null && i < jspMappings.length; i++) {
-                addServletMappingDecoded(jspMappings[i], child.getName());
+                addServletMapping(jspMappings[i], child.getName());
             }
         }
     }
@@ -2850,6 +2873,7 @@ public class StandardContext extends ContainerBase implements Context, Notificat
     }
 
 
+    @SuppressWarnings("deprecation")
     @Override
     public void addErrorPage(ErrorPage errorPage) {
         // Validate the input parameters
@@ -2862,6 +2886,7 @@ public class StandardContext extends ContainerBase implements Context, Notificat
                 if (log.isDebugEnabled()) {
                     log.debug(sm.getString("standardContext.errorPage.warning", location));
                 }
+                // Error page is already decoded, so don't decode a second time
                 errorPage.setLocationDecoded("/" + location);
             } else {
                 throw new IllegalArgumentException(sm.getString("standardContext.errorPage.error", location));
@@ -2999,6 +3024,13 @@ public class StandardContext extends ContainerBase implements Context, Notificat
 
 
     @Override
+    public void addServletMapping(String pattern, String name, boolean jspWildCard) {
+        addServletMappingDecoded(pattern, name, jspWildCard);
+    }
+
+
+    @Override
+    @Deprecated
     public void addServletMappingDecoded(String pattern, String name, boolean jspWildCard) {
         // Validate the proposed mapping
         if (findChild(name) == null) {
diff --git a/java/org/apache/catalina/startup/ContextConfig.java b/java/org/apache/catalina/startup/ContextConfig.java
index 6d20b1d672..08e3b5b1c1 100644
--- a/java/org/apache/catalina/startup/ContextConfig.java
+++ b/java/org/apache/catalina/startup/ContextConfig.java
@@ -1311,8 +1311,9 @@ public class ContextConfig implements LifecycleListener {
          * - If an SCI has a @HandlesType annotation then all classes (except those in JARs excluded from an absolute
          * ordering) need to be scanned to check if they match.
          */
+        @SuppressWarnings("deprecation")
         WebXmlParser webXmlParser = new WebXmlParser(context.getXmlNamespaceAware(), context.getXmlValidation(),
-                context.getXmlBlockExternal());
+                context.getXmlBlockExternal(), context.getUrlPatternsProvidedInDecodedForm());
 
         Set<WebXml> defaults = new HashSet<>();
         defaults.add(getDefaultWebXmlFragment(webXmlParser));
@@ -1593,7 +1594,7 @@ public class ContextConfig implements LifecycleListener {
             context.addChild(wrapper);
         }
         for (Entry<String,String> entry : webxml.getServletMappings().entrySet()) {
-            context.addServletMappingDecoded(entry.getKey(), entry.getValue());
+            context.addServletMapping(entry.getKey(), entry.getValue());
         }
         SessionConfig sessionConfig = webxml.getSessionConfig();
         if (sessionConfig != null) {
@@ -1631,7 +1632,7 @@ public class ContextConfig implements LifecycleListener {
             }
             if (context.findChild(jspServletName) != null) {
                 for (String urlPattern : jspPropertyGroup.getUrlPatterns()) {
-                    context.addServletMappingDecoded(urlPattern, jspServletName, true);
+                    context.addServletMapping(urlPattern, jspServletName, true);
                 }
             } else {
                 if (log.isDebugEnabled()) {
@@ -1824,8 +1825,9 @@ public class ContextConfig implements LifecycleListener {
      *
      * @return a new WebXml instance
      */
+    @SuppressWarnings("deprecation")
     protected WebXml createWebXml() {
-        return new WebXml();
+        return new WebXml(context.getUrlPatternsProvidedInDecodedForm());
     }
 
     /**
@@ -2152,7 +2154,8 @@ public class ContextConfig implements LifecycleListener {
         // - this fragment has metadata-complete="true"
         boolean htOnly = handlesTypesOnly || !fragment.getWebappJar() || fragment.isMetadataComplete();
 
-        WebXml annotations = new WebXml();
+        @SuppressWarnings("deprecation")
+        WebXml annotations = new WebXml(context.getUrlPatternsProvidedInDecodedForm());
         // no impact on distributable
         annotations.setDistributable(true);
         URL url = fragment.getURL();
@@ -2699,6 +2702,7 @@ public class ContextConfig implements LifecycleListener {
      * @param ae        The filter annotation
      * @param fragment  The corresponding fragment
      */
+    @SuppressWarnings("deprecation")
     protected void processAnnotationWebFilter(String className, AnnotationEntry ae, WebXml fragment) {
         String filterName = null;
         // must search for name s. Spec Servlet API 3.0 - 8.2.3.3.n.ii page 81
@@ -2742,8 +2746,12 @@ public class ContextConfig implements LifecycleListener {
                 urlPatterns = processAnnotationsStringArray(evp.getValue());
                 urlPatternsSet = urlPatterns.length > 0;
                 for (String urlPattern : urlPatterns) {
-                    // % decoded (if required) using UTF-8
-                    filterMap.addURLPattern(urlPattern);
+                    if (fragment.getUrlPatternsProvidedInDecodedForm()) {
+                        filterMap.addURLPatternDecoded(urlPattern);
+                    } else {
+                        // % decoded (if required) using UTF-8
+                        filterMap.addURLPattern(urlPattern);
+                    }
                 }
             } else if ("servletNames".equals(name)) {
                 String[] servletNames = processAnnotationsStringArray(evp.getValue());
diff --git a/java/org/apache/catalina/startup/FailedContext.java b/java/org/apache/catalina/startup/FailedContext.java
index 26dbcbd20a..65511d5d06 100644
--- a/java/org/apache/catalina/startup/FailedContext.java
+++ b/java/org/apache/catalina/startup/FailedContext.java
@@ -978,6 +978,12 @@ public class FailedContext extends LifecycleMBeanBase implements Context {
     }
 
     @Override
+    public void addServletMapping(String pattern, String name, boolean jspWildcard) {
+        // NO-OP
+    }
+
+    @Override
+    @Deprecated
     public void addServletMappingDecoded(String pattern, String name, boolean jspWildcard) {
         // NO-OP
     }
diff --git a/java/org/apache/catalina/startup/Tomcat.java b/java/org/apache/catalina/startup/Tomcat.java
index 294478e31d..9c6a4620d9 100644
--- a/java/org/apache/catalina/startup/Tomcat.java
+++ b/java/org/apache/catalina/startup/Tomcat.java
@@ -1048,9 +1048,9 @@ public class Tomcat {
         servlet.setOverridable(true);
 
         // Servlet mappings
-        ctx.addServletMappingDecoded("/", "default");
-        ctx.addServletMappingDecoded("*.jsp", "jsp");
-        ctx.addServletMappingDecoded("*.jspx", "jsp");
+        ctx.addServletMapping("/", "default");
+        ctx.addServletMapping("*.jsp", "jsp");
+        ctx.addServletMapping("*.jspx", "jsp");
 
         // Sessions
         ctx.setSessionTimeout(30);
diff --git a/java/org/apache/tomcat/util/descriptor/web/ErrorPage.java b/java/org/apache/tomcat/util/descriptor/web/ErrorPage.java
index 48bd659169..a1db5fbb4d 100644
--- a/java/org/apache/tomcat/util/descriptor/web/ErrorPage.java
+++ b/java/org/apache/tomcat/util/descriptor/web/ErrorPage.java
@@ -26,6 +26,7 @@ import org.apache.tomcat.util.buf.UDecoder;
  * Representation of an error page element for a web application, as represented in a <code>&lt;error-page&gt;</code>
  * element in the deployment descriptor.
  */
+@SuppressWarnings("deprecation")
 public class ErrorPage extends XmlEncodingBase implements Serializable {
 
     /**
@@ -142,7 +143,10 @@ public class ErrorPage extends XmlEncodingBase implements Serializable {
      * Set the already URL decoded location.
      *
      * @param location The new location
+     *
+     * @deprecated This method will be removed in Tomcat 12
      */
+    @Deprecated
     public void setLocationDecoded(String location) {
         this.location = location;
     }
diff --git a/java/org/apache/tomcat/util/descriptor/web/FilterMap.java b/java/org/apache/tomcat/util/descriptor/web/FilterMap.java
index 1e890ad27c..07d703f992 100644
--- a/java/org/apache/tomcat/util/descriptor/web/FilterMap.java
+++ b/java/org/apache/tomcat/util/descriptor/web/FilterMap.java
@@ -31,6 +31,7 @@ import org.apache.tomcat.util.buf.UDecoder;
  * element in the deployment descriptor. Each filter mapping must contain a filter name plus either a URL pattern or a
  * servlet name.
  */
+@SuppressWarnings("deprecation")
 public class FilterMap extends XmlEncodingBase implements Serializable {
 
     /**
@@ -197,7 +198,10 @@ public class FilterMap extends XmlEncodingBase implements Serializable {
      * Adds a decoded URL pattern to the set of URL patterns this mapping matches.
      *
      * @param urlPattern The decoded URL pattern to add
+     *
+     * @deprecated This method will be removed in Tomcat 12 onwards
      */
+    @Deprecated
     public void addURLPatternDecoded(String urlPattern) {
         if ("*".equals(urlPattern)) {
             this.matchAllUrlPatterns = true;
diff --git a/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java b/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java
index 78eb1d9c76..117a12df47 100644
--- a/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java
+++ b/java/org/apache/tomcat/util/descriptor/web/FragmentJarScannerCallback.java
@@ -58,7 +58,8 @@ public class FragmentJarScannerCallback implements JarScannerCallback {
     public void scan(Jar jar, String webappPath, boolean isWebapp) throws IOException {
 
         InputStream is = null;
-        WebXml fragment = new WebXml();
+        @SuppressWarnings("deprecation")
+        WebXml fragment = new WebXml(webXmlParser.getUrlPatternsProvidedInDecodedForm());
         fragment.setWebappJar(isWebapp);
         fragment.setDelegate(delegate);
 
@@ -104,7 +105,8 @@ public class FragmentJarScannerCallback implements JarScannerCallback {
     @Override
     public void scan(File file, String webappPath, boolean isWebapp) throws IOException {
 
-        WebXml fragment = new WebXml();
+        @SuppressWarnings("deprecation")
+        WebXml fragment = new WebXml(webXmlParser.getUrlPatternsProvidedInDecodedForm());
         fragment.setWebappJar(isWebapp);
         fragment.setDelegate(delegate);
 
diff --git a/java/org/apache/tomcat/util/descriptor/web/JspPropertyGroup.java b/java/org/apache/tomcat/util/descriptor/web/JspPropertyGroup.java
index 304bba3c67..42b4c0bb58 100644
--- a/java/org/apache/tomcat/util/descriptor/web/JspPropertyGroup.java
+++ b/java/org/apache/tomcat/util/descriptor/web/JspPropertyGroup.java
@@ -26,6 +26,7 @@ import org.apache.tomcat.util.buf.UDecoder;
 /**
  * Representation of a jsp-property-group element in web.xml.
  */
+@SuppressWarnings("deprecation")
 public class JspPropertyGroup extends XmlEncodingBase {
 
     /**
@@ -230,7 +231,9 @@ public class JspPropertyGroup extends XmlEncodingBase {
      * Adds a pre-decoded URL pattern to this property group.
      *
      * @param urlPattern the decoded URL pattern to add
+     * @deprecated This method will be removed in Tomcat 12
      */
+    @Deprecated
     public void addUrlPatternDecoded(String urlPattern) {
         this.urlPattern.add(urlPattern);
     }
diff --git a/java/org/apache/tomcat/util/descriptor/web/LoginConfig.java b/java/org/apache/tomcat/util/descriptor/web/LoginConfig.java
index 80c506b32f..bd3f09310f 100644
--- a/java/org/apache/tomcat/util/descriptor/web/LoginConfig.java
+++ b/java/org/apache/tomcat/util/descriptor/web/LoginConfig.java
@@ -25,6 +25,7 @@ import org.apache.tomcat.util.buf.UDecoder;
  * Representation of a login configuration element for a web application, as represented in a
  * <code>&lt;login-config&gt;</code> element in the deployment descriptor.
  */
+@SuppressWarnings("deprecation")
 public class LoginConfig extends XmlEncodingBase implements Serializable {
 
 
@@ -118,7 +119,10 @@ public class LoginConfig extends XmlEncodingBase implements Serializable {
      * Set the already decoded error page URI.
      *
      * @param errorPage the decoded errorPage to set
+     *
+     * @deprecated Will be removed in Tomcat 12 onwards
      */
+    @Deprecated
     public void setErrorPageDecoded(String errorPage) {
         this.errorPage = errorPage;
     }
@@ -152,7 +156,10 @@ public class LoginConfig extends XmlEncodingBase implements Serializable {
      * Set the already decoded login page URI.
      *
      * @param loginPage the decoded loginPage to set
+     *
+     * @deprecated Will be removed in Tomcat 12 onwards
      */
+    @Deprecated
     public void setLoginPageDecoded(String loginPage) {
         this.loginPage = loginPage;
     }
diff --git a/java/org/apache/tomcat/util/descriptor/web/SecurityCollection.java b/java/org/apache/tomcat/util/descriptor/web/SecurityCollection.java
index 9c595c92a7..97642b73aa 100644
--- a/java/org/apache/tomcat/util/descriptor/web/SecurityCollection.java
+++ b/java/org/apache/tomcat/util/descriptor/web/SecurityCollection.java
@@ -31,6 +31,7 @@ import org.apache.tomcat.util.buf.UDecoder;
  * single thread, before the instance is made visible to the remainder of the application. After that, only read access
  * is expected. Therefore, none of the read and write access within this class is synchronized.
  */
+@SuppressWarnings("deprecation")
 public class SecurityCollection extends XmlEncodingBase implements Serializable {
 
     @Serial
@@ -211,7 +212,10 @@ public class SecurityCollection extends XmlEncodingBase implements Serializable
      * Add a URL pattern (already decoded) to be part of this web resource collection.
      *
      * @param pattern The decoded pattern
+     *
+     * @deprecated Will be removed in Tomcat 12 onwards
      */
+    @Deprecated
     public void addPatternDecoded(String pattern) {
 
         if (pattern == null) {
diff --git a/java/org/apache/tomcat/util/descriptor/web/SecurityConstraint.java b/java/org/apache/tomcat/util/descriptor/web/SecurityConstraint.java
index 785a352d0b..10c6069947 100644
--- a/java/org/apache/tomcat/util/descriptor/web/SecurityConstraint.java
+++ b/java/org/apache/tomcat/util/descriptor/web/SecurityConstraint.java
@@ -46,6 +46,7 @@ import org.apache.tomcat.util.res.StringManager;
  * single thread, before the instance is made visible to the remainder of the application. After that, only read access
  * is expected. Therefore, none of the read and write access within this class is synchronized.
  */
+@SuppressWarnings("deprecation")
 public class SecurityConstraint extends XmlEncodingBase implements Serializable {
 
     @Serial
diff --git a/java/org/apache/tomcat/util/descriptor/web/WebRuleSet.java b/java/org/apache/tomcat/util/descriptor/web/WebRuleSet.java
index ab1d1a7634..3f5da0c700 100644
--- a/java/org/apache/tomcat/util/descriptor/web/WebRuleSet.java
+++ b/java/org/apache/tomcat/util/descriptor/web/WebRuleSet.java
@@ -96,8 +96,10 @@ public class WebRuleSet implements RuleSet {
     protected final RelativeOrderingRule relativeOrdering;
 
 
-    // ------------------------------------------------------------ Constructor
+    private final boolean urlPatternsProvidedInDecodedForm;
+
 
+    // ------------------------------------------------------------ Constructor
 
     /**
      * Construct an instance of this <code>RuleSet</code> with the default matching pattern prefix and default fragment
@@ -129,6 +131,22 @@ public class WebRuleSet implements RuleSet {
      * @param fragment <code>true</code> if this is a web fragment
      */
     public WebRuleSet(String prefix, boolean fragment) {
+        this(prefix, fragment, false);
+    }
+
+
+    /**
+     * Construct an instance of this <code>RuleSet</code> with the specified matching pattern prefix.
+     *
+     * @param prefix                           Prefix for matching pattern rules (including the trailing slash
+     *                                             character)
+     * @param fragment                         <code>true</code> if this is a web fragment
+     * @param urlPatternsProvidedInDecodedForm Whether URL and URL patterns will be provided in decoded form
+     *
+     * @deprecated This constructor will be removed in Tomcat 12
+     */
+    @Deprecated
+    public WebRuleSet(String prefix, boolean fragment, boolean urlPatternsProvidedInDecodedForm) {
         this.prefix = prefix;
         this.fragment = fragment;
 
@@ -140,6 +158,7 @@ public class WebRuleSet implements RuleSet {
 
         absoluteOrdering = new AbsoluteOrderingRule(fragment);
         relativeOrdering = new RelativeOrderingRule(fragment);
+        this.urlPatternsProvidedInDecodedForm = urlPatternsProvidedInDecodedForm;
     }
 
 
@@ -195,7 +214,11 @@ public class WebRuleSet implements RuleSet {
 
         digester.addCallMethod(fullPrefix + "/error-page/error-code", "setErrorCode", 0);
         digester.addCallMethod(fullPrefix + "/error-page/exception-type", "setExceptionType", 0);
-        digester.addCallMethod(fullPrefix + "/error-page/location", "setLocation", 0);
+        if (urlPatternsProvidedInDecodedForm) {
+            digester.addCallMethod(fullPrefix + "/error-page/location", "setLocationDecoded", 0);
+        } else {
+            digester.addCallMethod(fullPrefix + "/error-page/location", "setLocation", 0);
+        }
 
         digester.addObjectCreate(fullPrefix + "/filter", "org.apache.tomcat.util.descriptor.web.FilterDef");
         digester.addSetNext(fullPrefix + "/filter", "addFilter", "org.apache.tomcat.util.descriptor.web.FilterDef");
@@ -218,7 +241,11 @@ public class WebRuleSet implements RuleSet {
 
         digester.addCallMethod(fullPrefix + "/filter-mapping/filter-name", "setFilterName", 0);
         digester.addCallMethod(fullPrefix + "/filter-mapping/servlet-name", "addServletName", 0);
-        digester.addCallMethod(fullPrefix + "/filter-mapping/url-pattern", "addURLPattern", 0);
+        if (urlPatternsProvidedInDecodedForm) {
+            digester.addCallMethod(fullPrefix + "/filter-mapping/url-pattern", "addURLPatternDecoded", 0);
+        } else {
+            digester.addCallMethod(fullPrefix + "/filter-mapping/url-pattern", "addURLPattern", 0);
+        }
 
         digester.addCallMethod(fullPrefix + "/filter-mapping/dispatcher", "setDispatcher", 0);
 
@@ -243,7 +270,12 @@ public class WebRuleSet implements RuleSet {
                 0);
         digester.addCallMethod(fullPrefix + "/jsp-config/jsp-property-group/trim-directive-whitespaces",
                 "setTrimWhitespace", 0);
-        digester.addCallMethod(fullPrefix + "/jsp-config/jsp-property-group/url-pattern", "addUrlPattern", 0);
+        if (urlPatternsProvidedInDecodedForm) {
+            digester.addCallMethod(fullPrefix + "/jsp-config/jsp-property-group/url-pattern", "addUrlPatternDecoded",
+                    0);
+        } else {
+            digester.addCallMethod(fullPrefix + "/jsp-config/jsp-property-group/url-pattern", "addUrlPattern", 0);
+        }
         digester.addCallMethod(fullPrefix + "/jsp-config/jsp-property-group/default-content-type",
                 "setDefaultContentType", 0);
         digester.addCallMethod(fullPrefix + "/jsp-config/jsp-property-group/buffer", "setBuffer", 0);
@@ -258,8 +290,16 @@ public class WebRuleSet implements RuleSet {
 
         digester.addCallMethod(fullPrefix + "/login-config/auth-method", "setAuthMethod", 0);
         digester.addCallMethod(fullPrefix + "/login-config/realm-name", "setRealmName", 0);
-        digester.addCallMethod(fullPrefix + "/login-config/form-login-config/form-error-page", "setErrorPage", 0);
-        digester.addCallMethod(fullPrefix + "/login-config/form-login-config/form-login-page", "setLoginPage", 0);
+
+        if (urlPatternsProvidedInDecodedForm) {
+            digester.addCallMethod(fullPrefix + "/login-config/form-login-config/form-error-page",
+                    "setErrorPageDecoded", 0);
+            digester.addCallMethod(fullPrefix + "/login-config/form-login-config/form-login-page",
+                    "setLoginPageDecoded", 0);
+        } else {
+            digester.addCallMethod(fullPrefix + "/login-config/form-login-config/form-error-page", "setErrorPage", 0);
+            digester.addCallMethod(fullPrefix + "/login-config/form-login-config/form-login-page", "setLoginPage", 0);
+        }
 
         digester.addCallMethod(fullPrefix + "/mime-mapping", "addMimeMapping", 2);
         digester.addCallParam(fullPrefix + "/mime-mapping/extension", 0);
@@ -284,8 +324,13 @@ public class WebRuleSet implements RuleSet {
         digester.addCallMethod(fullPrefix + "/security-constraint/web-resource-collection/http-method", "addMethod", 0);
         digester.addCallMethod(fullPrefix + "/security-constraint/web-resource-collection/http-method-omission",
                 "addOmittedMethod", 0);
-        digester.addCallMethod(fullPrefix + "/security-constraint/web-resource-collection/url-pattern", "addPattern",
-                0);
+        if (urlPatternsProvidedInDecodedForm) {
+            digester.addCallMethod(fullPrefix + "/security-constraint/web-resource-collection/url-pattern",
+                    "addPatternDecoded", 0);
+        } else {
+            digester.addCallMethod(fullPrefix + "/security-constraint/web-resource-collection/url-pattern",
+                    "addPattern", 0);
+        }
         digester.addCallMethod(fullPrefix + "/security-constraint/web-resource-collection/web-resource-name", "setName",
                 0);
 
diff --git a/java/org/apache/tomcat/util/descriptor/web/WebXml.java b/java/org/apache/tomcat/util/descriptor/web/WebXml.java
index 952e5ef6dc..cb98721820 100644
--- a/java/org/apache/tomcat/util/descriptor/web/WebXml.java
+++ b/java/org/apache/tomcat/util/descriptor/web/WebXml.java
@@ -58,12 +58,28 @@ import org.apache.tomcat.util.security.Escape;
  * (e.g. single login-config) This class checks for invalid duplicates (e.g. filter/servlet names) StandardContext will
  * check validity of values (e.g. URL formats etc)
  */
+@SuppressWarnings("deprecation")
 public class WebXml extends XmlEncodingBase implements DocumentProperties.Charset {
 
     /**
      * Constructs a new WebXml.
      */
     public WebXml() {
+        this(false);
+    }
+
+    /**
+     * Constructs a new WebXml with configurable behaviour for URL and URL pattern decoding.
+     *
+     * @param urlPatternsProvidedInDecodedForm {@code true} if URLs and URL patterns are expected to be decoded.
+     *                                             {@code false} if they are expected to be URL-encoded (i.e.
+     *                                             {@code %nn} encoding)
+     *
+     * @deprecated This constructor will be removed in Tomcat 12
+     */
+    @Deprecated
+    public WebXml(boolean urlPatternsProvidedInDecodedForm) {
+        this.urlPatternsProvidedInDecodedForm = urlPatternsProvidedInDecodedForm;
     }
 
     /**
@@ -77,6 +93,26 @@ public class WebXml extends XmlEncodingBase implements DocumentProperties.Charse
 
     private final UEncoder urlEncoder = new UEncoder(SafeCharsSet.WITH_SLASH);
 
+    private final boolean urlPatternsProvidedInDecodedForm;
+
+
+    /**
+     * Does this Context expect URLs and URL patterns provided in web.xml, annotations and their programmatic
+     * equivalents to be in URL-decoded form?
+     * <p>
+     * As per the Servlet specification, "URI paths specified in the deployment descriptor are assumed to be in
+     * URL-decoded form.".
+     *
+     * @return {@code true} if URLs and URL patterns are expected in URL-decoded form, otherwise {@code false}
+     *
+     * @deprecated This method will be removed in Tomcat 12 where the field will be effectively hard-coded to
+     *                 {@code true}
+     */
+    @Deprecated
+    public boolean getUrlPatternsProvidedInDecodedForm() {
+        return urlPatternsProvidedInDecodedForm;
+    }
+
     /**
      * Global defaults are overridable but Servlets and Servlet mappings need to be unique. Duplicates normally trigger
      * an error. This flag indicates if newly added Servlet elements are marked as overridable.
@@ -492,8 +528,8 @@ public class WebXml extends XmlEncodingBase implements DocumentProperties.Charse
     /**
      * Adds a context parameter.
      *
-     * @param param  The parameter name
-     * @param value  The parameter value
+     * @param param The parameter name
+     * @param value The parameter value
      */
     public void addContextParam(String param, String value) {
         contextParams.put(param, value);
@@ -625,21 +661,27 @@ public class WebXml extends XmlEncodingBase implements DocumentProperties.Charse
     /**
      * Adds a servlet URL mapping.
      *
-     * @param urlPattern   The URL pattern
-     * @param servletName  The servlet name
+     * @param urlPattern  The URL pattern
+     * @param servletName The servlet name
      */
     public void addServletMapping(String urlPattern, String servletName) {
-        addServletMappingDecoded(UDecoder.URLDecode(urlPattern, getCharset()), servletName);
+        if (!urlPatternsProvidedInDecodedForm) {
+            urlPattern = UDecoder.URLDecode(urlPattern, getCharset());
+        }
+        addServletMappingDecoded(urlPattern, servletName);
     }
 
     /**
      * Adds a servlet URL mapping (already decoded).
      *
-     * @param urlPattern   The URL pattern
-     * @param servletName  The servlet name
+     * @param urlPattern  The URL pattern
+     * @param servletName The servlet name
      *
      * @throws IllegalArgumentException If a duplicate mapping exists
+     *
+     * @deprecated Will be removed in Tomcat 12 onwards
      */
+    @Deprecated
     public void addServletMappingDecoded(String urlPattern, String servletName) {
         String oldServletName = servletMappings.put(urlPattern, servletName);
         if (oldServletName != null) {
@@ -688,8 +730,8 @@ public class WebXml extends XmlEncodingBase implements DocumentProperties.Charse
     /**
      * Adds a MIME mapping.
      *
-     * @param extension  The file extension
-     * @param mimeType   The MIME type
+     * @param extension The file extension
+     * @param mimeType  The MIME type
      */
     public void addMimeMapping(String extension, String mimeType) {
         mimeMappings.put(extension, mimeType);
@@ -1779,7 +1821,8 @@ public class WebXml extends XmlEncodingBase implements DocumentProperties.Charse
                 }
                 sb.append("    </web-resource-collection>\n");
             }
-            if (constraint.findAuthRoles().length > 0 || constraint.getAllRoles() || constraint.getAuthenticatedUsers()) {
+            if (constraint.findAuthRoles().length > 0 || constraint.getAllRoles() ||
+                    constraint.getAuthenticatedUsers()) {
                 sb.append("    <auth-constraint>\n");
                 for (String role : constraint.findAuthRoles()) {
                     appendElement(sb, INDENT6, "role-name", role);
@@ -2092,7 +2135,7 @@ public class WebXml extends XmlEncodingBase implements DocumentProperties.Charse
 
         // Merge rules vary from element to element. See SRV.8.2.3
 
-        WebXml temp = new WebXml();
+        WebXml temp = new WebXml(urlPatternsProvidedInDecodedForm);
 
         for (WebXml fragment : fragments) {
             if (!mergeMap(fragment.getContextParams(), contextParams, temp.getContextParams(), fragment,
diff --git a/java/org/apache/tomcat/util/descriptor/web/WebXmlParser.java b/java/org/apache/tomcat/util/descriptor/web/WebXmlParser.java
index a25a72de11..4806442d23 100644
--- a/java/org/apache/tomcat/util/descriptor/web/WebXmlParser.java
+++ b/java/org/apache/tomcat/util/descriptor/web/WebXmlParser.java
@@ -52,24 +52,43 @@ public class WebXmlParser {
      */
     private final Digester webFragmentDigester;
     private final WebRuleSet webFragmentRuleSet;
-
+    private final boolean urlPatternsProvidedInDecodedForm;
 
     /**
      * Constructs a new WebXmlParser.
      *
-     * @param namespaceAware  Whether the parser is namespace aware
-     * @param validation      Whether validation is enabled
-     * @param blockExternal   Whether external entities are blocked
+     * @param namespaceAware Whether the parser is namespace aware
+     * @param validation     Whether validation is enabled
+     * @param blockExternal  Whether external entities are blocked
      */
     public WebXmlParser(boolean namespaceAware, boolean validation, boolean blockExternal) {
-        webRuleSet = new WebRuleSet(false);
+        this(namespaceAware, validation, blockExternal, false);
+    }
+
+
+    /**
+     * Constructs a new WebXmlParser.
+     *
+     * @param namespaceAware                   Whether the parser is namespace aware
+     * @param validation                       Whether validation is enabled
+     * @param blockExternal                    Whether external entities are blocked
+     * @param urlPatternsProvidedInDecodedForm Whether URL and URL patterns will be provided in decoded form
+     *
+     * @deprecated This constructor will be removed in Tomcat 12
+     */
+    @Deprecated
+    public WebXmlParser(boolean namespaceAware, boolean validation, boolean blockExternal,
+            boolean urlPatternsProvidedInDecodedForm) {
+
+        webRuleSet = new WebRuleSet("",  false, urlPatternsProvidedInDecodedForm);
         webDigester = DigesterFactory.newDigester(validation, namespaceAware, webRuleSet, blockExternal);
         webDigester.getParser();
 
-        webFragmentRuleSet = new WebRuleSet(true);
+        webFragmentRuleSet = new WebRuleSet("", true, urlPatternsProvidedInDecodedForm);
         webFragmentDigester =
                 DigesterFactory.newDigester(validation, namespaceAware, webFragmentRuleSet, blockExternal);
         webFragmentDigester.getParser();
+        this.urlPatternsProvidedInDecodedForm = urlPatternsProvidedInDecodedForm;
     }
 
     /**
@@ -163,4 +182,18 @@ public class WebXmlParser {
         webDigester.setClassLoader(classLoader);
         webFragmentDigester.setClassLoader(classLoader);
     }
-}
\ No newline at end of file
+
+
+    /**
+     * Does this parser expect URLs and URL patterns provided in web.xml, annotations and their programmatic
+     * equivalents to be in URL-decoded form?
+     *
+     * @return {@code true} if URLs and URL patterns are expected in URL-decoded form, otherwise {@code false}
+     *
+     * @deprecated This method will be removed in Tomcat 12 where it will effectively be hard-coded to {@code true}
+     */
+    @Deprecated
+    public boolean getUrlPatternsProvidedInDecodedForm() {
+        return urlPatternsProvidedInDecodedForm;
+    }
+}
diff --git a/java/org/apache/tomcat/util/descriptor/web/XmlEncodingBase.java b/java/org/apache/tomcat/util/descriptor/web/XmlEncodingBase.java
index 9c8f96c89f..666f7c2525 100644
--- a/java/org/apache/tomcat/util/descriptor/web/XmlEncodingBase.java
+++ b/java/org/apache/tomcat/util/descriptor/web/XmlEncodingBase.java
@@ -21,23 +21,29 @@ import java.nio.charset.StandardCharsets;
 
 /**
  * Base class for those elements that need to track the encoding used in the source XML.
+ *
+ * @deprecated This abstract class will be removed in Tomcat 12 onwards
  */
+@Deprecated
 public abstract class XmlEncodingBase {
 
+    private Charset charset = StandardCharsets.UTF_8;
+
+
     /**
      * Default constructor.
      */
+    @Deprecated
     public XmlEncodingBase() {
     }
 
-    private Charset charset = StandardCharsets.UTF_8;
-
 
     /**
      * Set the character encoding of the XML source used to populate this object.
      *
      * @param charset The character encoding
      */
+    @Deprecated
     public void setCharset(Charset charset) {
         this.charset = charset;
     }
@@ -49,6 +55,7 @@ public abstract class XmlEncodingBase {
      * @return The character encoding of the associated XML source or <code>UTF-8</code> if the encoding could not be
      *             determined
      */
+    @Deprecated
     public Charset getCharset() {
         return charset;
     }
diff --git a/test/jakarta/servlet/TestServletRequestParameters.java b/test/jakarta/servlet/TestServletRequestParameters.java
index 20c26b3c52..9d1c11630a 100644
--- a/test/jakarta/servlet/TestServletRequestParameters.java
+++ b/test/jakarta/servlet/TestServletRequestParameters.java
@@ -43,7 +43,7 @@ public class TestServletRequestParameters extends ServletRequestParametersBaseTe
         // Map the test Servlet
         ParameterParsingServlet parameterParsingServlet = new ParameterParsingServlet();
         Tomcat.addServlet(ctx, "parameterParsingServlet", parameterParsingServlet);
-        ctx.addServletMappingDecoded("/", "parameterParsingServlet");
+        ctx.addServletMapping("/", "parameterParsingServlet");
 
         tomcat.start();
 
diff --git a/test/jakarta/servlet/TestServletRequestParametersFormUrlEncoded.java b/test/jakarta/servlet/TestServletRequestParametersFormUrlEncoded.java
index 39db12e3fa..d45458e553 100644
--- a/test/jakarta/servlet/TestServletRequestParametersFormUrlEncoded.java
+++ b/test/jakarta/servlet/TestServletRequestParametersFormUrlEncoded.java
@@ -65,7 +65,7 @@ public class TestServletRequestParametersFormUrlEncoded extends ServletRequestPa
         // Map the test Servlet
         ParameterParsingServlet parameterParsingServlet = new ParameterParsingServlet();
         Tomcat.addServlet(ctx, "parameterParsingServlet", parameterParsingServlet);
-        ctx.addServletMappingDecoded("/", "parameterParsingServlet");
+        ctx.addServletMapping("/", "parameterParsingServlet");
 
         tomcat.start();
 
diff --git a/test/jakarta/servlet/TestServletRequestParametersMultipartEncoded.java b/test/jakarta/servlet/TestServletRequestParametersMultipartEncoded.java
index ebd0f132f7..f1cbe15b81 100644
--- a/test/jakarta/servlet/TestServletRequestParametersMultipartEncoded.java
+++ b/test/jakarta/servlet/TestServletRequestParametersMultipartEncoded.java
@@ -65,7 +65,7 @@ public class TestServletRequestParametersMultipartEncoded extends ServletRequest
         // Map the test Servlet
         ParameterParsingServlet parameterParsingServlet = new ParameterParsingServlet();
         Tomcat.addServlet(ctx, "parameterParsingServlet", parameterParsingServlet);
-        ctx.addServletMappingDecoded("/", "parameterParsingServlet");
+        ctx.addServletMapping("/", "parameterParsingServlet");
 
         tomcat.start();
 
diff --git a/test/jakarta/servlet/TestServletRequestParametersQueryString.java b/test/jakarta/servlet/TestServletRequestParametersQueryString.java
index 0e76a055f4..939d1a4bf7 100644
--- a/test/jakarta/servlet/TestServletRequestParametersQueryString.java
+++ b/test/jakarta/servlet/TestServletRequestParametersQueryString.java
@@ -88,7 +88,7 @@ public class TestServletRequestParametersQueryString extends ServletRequestParam
         // Map the test Servlet
         ParameterParsingServlet parameterParsingServlet = new ParameterParsingServlet();
         Tomcat.addServlet(ctx, "parameterParsingServlet", parameterParsingServlet);
-        ctx.addServletMappingDecoded("/", "parameterParsingServlet");
+        ctx.addServletMapping("/", "parameterParsingServlet");
 
         tomcat.start();
 
diff --git a/test/jakarta/servlet/annotation/TestServletSecurity.java b/test/jakarta/servlet/annotation/TestServletSecurity.java
index 4782922ec6..ff97b5667a 100644
--- a/test/jakarta/servlet/annotation/TestServletSecurity.java
+++ b/test/jakarta/servlet/annotation/TestServletSecurity.java
@@ -53,10 +53,10 @@ public class TestServletSecurity extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "Foo", Foo.class.getName());
-        ctx.addServletMappingDecoded("/foo/*", "Foo");
+        ctx.addServletMapping("/foo/*", "Foo");
 
         Tomcat.addServlet(ctx, "FooBar", FooBar.class.getName());
-        ctx.addServletMappingDecoded("/foo/bar/*", "FooBar");
+        ctx.addServletMapping("/foo/bar/*", "FooBar");
 
         tomcat.start();
 
diff --git a/test/jakarta/servlet/http/HttpServletDoHeadBaseTest.java b/test/jakarta/servlet/http/HttpServletDoHeadBaseTest.java
index 4bf271e7e8..06033d6d9a 100644
--- a/test/jakarta/servlet/http/HttpServletDoHeadBaseTest.java
+++ b/test/jakarta/servlet/http/HttpServletDoHeadBaseTest.java
@@ -213,7 +213,7 @@ public class HttpServletDoHeadBaseTest extends Http2TestBase {
         StandardContext ctxt = (StandardContext) getProgrammaticRootContext();
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         HeadTestServlet s = new HeadTestServlet(bufferSize, useWriter, invalidWriteCount, resetType, validWriteCount,
                 explicitFlush);
@@ -221,7 +221,7 @@ public class HttpServletDoHeadBaseTest extends Http2TestBase {
         if (useLegacy) {
             w.addInitParameter(HttpServlet.LEGACY_DO_HEAD, "true");
         }
-        ctxt.addServletMappingDecoded("/test", "HeadTestServlet");
+        ctxt.addServletMapping("/test", "HeadTestServlet");
 
         tomcat.start();
     }
diff --git a/test/jakarta/servlet/http/TestHttpServlet.java b/test/jakarta/servlet/http/TestHttpServlet.java
index b92febb99d..e78b4a45e4 100644
--- a/test/jakarta/servlet/http/TestHttpServlet.java
+++ b/test/jakarta/servlet/http/TestHttpServlet.java
@@ -57,7 +57,7 @@ public class TestHttpServlet extends TomcatBaseTest {
         // Map the test Servlet
         LargeBodyServlet largeBodyServlet = new LargeBodyServlet();
         Tomcat.addServlet(ctx, "largeBodyServlet", largeBodyServlet);
-        ctx.addServletMappingDecoded("/", "largeBodyServlet");
+        ctx.addServletMapping("/", "largeBodyServlet");
 
         tomcat.start();
 
@@ -94,11 +94,11 @@ public class TestHttpServlet extends TomcatBaseTest {
 
         Bug57602ServletOuter outer = new Bug57602ServletOuter();
         Tomcat.addServlet(ctx, "Bug57602ServletOuter", outer);
-        ctx.addServletMappingDecoded("/outer", "Bug57602ServletOuter");
+        ctx.addServletMapping("/outer", "Bug57602ServletOuter");
 
         Bug57602ServletInner inner = new Bug57602ServletInner();
         Tomcat.addServlet(ctx, "Bug57602ServletInner", inner);
-        ctx.addServletMappingDecoded("/inner", "Bug57602ServletInner");
+        ctx.addServletMapping("/inner", "Bug57602ServletInner");
 
         tomcat.start();
 
@@ -167,7 +167,7 @@ public class TestHttpServlet extends TomcatBaseTest {
         Wrapper w = Tomcat.addServlet(ctx, "TestServlet", servlet);
         // Not all need/use this but it is simpler to set it for all
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/test", "TestServlet");
+        ctx.addServletMapping("/test", "TestServlet");
 
         tomcat.start();
 
@@ -241,7 +241,7 @@ public class TestHttpServlet extends TomcatBaseTest {
         // Map the test Servlet
         OptionsServletQuery servlet = new OptionsServletQuery();
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -278,7 +278,7 @@ public class TestHttpServlet extends TomcatBaseTest {
         // Map the test Servlet
         OptionsServletQuery servlet = new OptionsServletQuery();
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -313,7 +313,7 @@ public class TestHttpServlet extends TomcatBaseTest {
         // Map the test Servlet
         ParamsServlet servlet = new ParamsServlet();
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -350,7 +350,7 @@ public class TestHttpServlet extends TomcatBaseTest {
 
         // Map the test Servlet
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -422,7 +422,7 @@ public class TestHttpServlet extends TomcatBaseTest {
 
         // Map the test Servlet
         Tomcat.addServlet(ctx, "servlet", new SimpleServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -485,7 +485,7 @@ public class TestHttpServlet extends TomcatBaseTest {
 
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "TesterServlet", new TesterServlet());
-            root.addServletMappingDecoded("/test", "TesterServlet");
+            root.addServletMapping("/test", "TesterServlet");
 
             try {
                 tomcat.start();
diff --git a/test/jakarta/servlet/http/TestHttpServletResponseSendError.java b/test/jakarta/servlet/http/TestHttpServletResponseSendError.java
index 52b332e6e1..13622bc688 100644
--- a/test/jakarta/servlet/http/TestHttpServletResponseSendError.java
+++ b/test/jakarta/servlet/http/TestHttpServletResponseSendError.java
@@ -138,14 +138,14 @@ public class TestHttpServletResponseSendError extends TomcatBaseTest {
         } else {
             Tomcat.addServlet(ctx, "target", new TesterServlet(throwException));
         }
-        ctx.addServletMappingDecoded("/target", "target");
+        ctx.addServletMapping("/target", "target");
         Tomcat.addServlet(ctx, "dispatch", new TesterDispatchServlet());
-        ctx.addServletMappingDecoded("/dispatch", "dispatch");
+        ctx.addServletMapping("/dispatch", "dispatch");
 
         Tomcat.addServlet(ctx, "error599", new ErrorServletStatic599());
-        ctx.addServletMappingDecoded("/error599", "error599");
+        ctx.addServletMapping("/error599", "error599");
         Tomcat.addServlet(ctx, "errorException", new ErrorServletStaticException());
-        ctx.addServletMappingDecoded("/errorException", "errorException");
+        ctx.addServletMapping("/errorException", "errorException");
 
         ErrorPage ep1 = new ErrorPage();
         ep1.setErrorCode(599);
diff --git a/test/org/apache/catalina/authenticator/TestAuthInfoResponseHeaders.java b/test/org/apache/catalina/authenticator/TestAuthInfoResponseHeaders.java
index b3a8dd0112..ae88c4f00f 100644
--- a/test/org/apache/catalina/authenticator/TestAuthInfoResponseHeaders.java
+++ b/test/org/apache/catalina/authenticator/TestAuthInfoResponseHeaders.java
@@ -141,9 +141,9 @@ public class TestAuthInfoResponseHeaders extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctxt, "TesterServlet", new TesterServlet());
-        ctxt.addServletMappingDecoded(URI, "TesterServlet");
+        ctxt.addServletMapping(URI, "TesterServlet");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI);
+        collection.addPattern(URI);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
         sc.addCollection(collection);
diff --git a/test/org/apache/catalina/authenticator/TestAuthenticatorBaseCorsPreflight.java b/test/org/apache/catalina/authenticator/TestAuthenticatorBaseCorsPreflight.java
index 5d2cacb220..46b8c700e2 100644
--- a/test/org/apache/catalina/authenticator/TestAuthenticatorBaseCorsPreflight.java
+++ b/test/org/apache/catalina/authenticator/TestAuthenticatorBaseCorsPreflight.java
@@ -117,7 +117,7 @@ public class TestAuthenticatorBaseCorsPreflight extends TomcatBaseTest {
         Context ctx = tomcat.addContext("", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         LoginConfig loginConfig = new LoginConfig();
         loginConfig.setAuthMethod("BASIC");
@@ -143,7 +143,7 @@ public class TestAuthenticatorBaseCorsPreflight extends TomcatBaseTest {
         otherFilter.setFilterClass(AddDefaultCharsetFilter.class.getName());
         FilterMap otherMap = new FilterMap();
         otherMap.setFilterName("other");
-        otherMap.addURLPatternDecoded("/other");
+        otherMap.addURLPattern("/other");
         ctx.addFilterDef(otherFilter);
         ctx.addFilterMap(otherMap);
 
@@ -154,7 +154,7 @@ public class TestAuthenticatorBaseCorsPreflight extends TomcatBaseTest {
         corsFilter.addInitParameter(CorsFilter.PARAM_CORS_ALLOWED_METHODS, ALLOWED_METHOD);
         FilterMap corsFilterMap = new FilterMap();
         corsFilterMap.setFilterName("cors");
-        corsFilterMap.addURLPatternDecoded(filterMapping);
+        corsFilterMap.addURLPattern(filterMapping);
         ctx.addFilterDef(corsFilter);
         ctx.addFilterMap(corsFilterMap);
 
diff --git a/test/org/apache/catalina/authenticator/TestDigestAuthenticator.java b/test/org/apache/catalina/authenticator/TestDigestAuthenticator.java
index 72f9bf5039..0ebff3d297 100644
--- a/test/org/apache/catalina/authenticator/TestDigestAuthenticator.java
+++ b/test/org/apache/catalina/authenticator/TestDigestAuthenticator.java
@@ -248,9 +248,9 @@ public class TestDigestAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctxt, "TesterServlet", new TesterServlet());
-        ctxt.addServletMappingDecoded(URI, "TesterServlet");
+        ctxt.addServletMapping(URI, "TesterServlet");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI);
+        collection.addPattern(URI);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
         sc.addCollection(collection);
diff --git a/test/org/apache/catalina/authenticator/TestDigestAuthenticatorAlgorithms.java b/test/org/apache/catalina/authenticator/TestDigestAuthenticatorAlgorithms.java
index d5027c4b4c..c3d2d0eca7 100644
--- a/test/org/apache/catalina/authenticator/TestDigestAuthenticatorAlgorithms.java
+++ b/test/org/apache/catalina/authenticator/TestDigestAuthenticatorAlgorithms.java
@@ -131,9 +131,9 @@ public class TestDigestAuthenticatorAlgorithms extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctxt, "TesterServlet", new TesterServlet());
-        ctxt.addServletMappingDecoded(URI, "TesterServlet");
+        ctxt.addServletMapping(URI, "TesterServlet");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI);
+        collection.addPattern(URI);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole("role");
         sc.addCollection(collection);
diff --git a/test/org/apache/catalina/authenticator/TestDigestAuthenticatorB.java b/test/org/apache/catalina/authenticator/TestDigestAuthenticatorB.java
index ae64f34a83..6173a9bd41 100644
--- a/test/org/apache/catalina/authenticator/TestDigestAuthenticatorB.java
+++ b/test/org/apache/catalina/authenticator/TestDigestAuthenticatorB.java
@@ -83,9 +83,9 @@ public class TestDigestAuthenticatorB extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctxt, "TesterServlet", new TesterServlet());
-        ctxt.addServletMappingDecoded(targetURI, "TesterServlet");
+        ctxt.addServletMapping(targetURI, "TesterServlet");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(targetURI);
+        collection.addPattern(targetURI);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(serverPermittedRole);
         sc.addCollection(collection);
diff --git a/test/org/apache/catalina/authenticator/TestFormAuthenticatorA.java b/test/org/apache/catalina/authenticator/TestFormAuthenticatorA.java
index 4ca6374d55..0be13c8119 100644
--- a/test/org/apache/catalina/authenticator/TestFormAuthenticatorA.java
+++ b/test/org/apache/catalina/authenticator/TestFormAuthenticatorA.java
@@ -594,18 +594,18 @@ public class TestFormAuthenticatorA extends TomcatBaseTest {
 
             Context ctx = tomcat.addContext("", System.getProperty("java.io.tmpdir"));
             Tomcat.addServlet(ctx, "SelectedMethods", new SelectedMethodsServlet());
-            ctx.addServletMappingDecoded("/test", "SelectedMethods");
+            ctx.addServletMapping("/test", "SelectedMethods");
             // Login servlet just needs to respond "OK". Client will handle
             // creating a valid response. No need for a form.
             Tomcat.addServlet(ctx, "Login", new TesterServlet());
-            ctx.addServletMappingDecoded("/login", "Login");
+            ctx.addServletMapping("/login", "Login");
 
             // Configure the security constraints
             SecurityConstraint constraint = new SecurityConstraint();
             SecurityCollection collection = new SecurityCollection();
             collection.setName("Protect PUT");
             collection.addMethod(Method.PUT);
-            collection.addPatternDecoded("/test");
+            collection.addPattern("/test");
             constraint.addCollection(collection);
             constraint.addAuthRole("tomcat");
             ctx.addConstraint(constraint);
diff --git a/test/org/apache/catalina/authenticator/TestNonLoginAndBasicAuthenticator.java b/test/org/apache/catalina/authenticator/TestNonLoginAndBasicAuthenticator.java
index 9fa537ae01..e0a3b5ba22 100644
--- a/test/org/apache/catalina/authenticator/TestNonLoginAndBasicAuthenticator.java
+++ b/test/org/apache/catalina/authenticator/TestNonLoginAndBasicAuthenticator.java
@@ -395,10 +395,10 @@ public class TestNonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet to the context
         Tomcat.addServlet(nonloginContext, "TesterServlet1", new TesterServlet());
-        nonloginContext.addServletMappingDecoded(URI_PROTECTED, "TesterServlet1");
+        nonloginContext.addServletMapping(URI_PROTECTED, "TesterServlet1");
 
         SecurityCollection collection1 = new SecurityCollection();
-        collection1.addPatternDecoded(URI_PROTECTED);
+        collection1.addPattern(URI_PROTECTED);
         SecurityConstraint sc1 = new SecurityConstraint();
         sc1.addAuthRole(ROLE);
         sc1.addCollection(collection1);
@@ -406,10 +406,10 @@ public class TestNonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add unprotected servlet to the context
         Tomcat.addServlet(nonloginContext, "TesterServlet2", new TesterServlet());
-        nonloginContext.addServletMappingDecoded(URI_PUBLIC, "TesterServlet2");
+        nonloginContext.addServletMapping(URI_PUBLIC, "TesterServlet2");
 
         SecurityCollection collection2 = new SecurityCollection();
-        collection2.addPatternDecoded(URI_PUBLIC);
+        collection2.addPattern(URI_PUBLIC);
         SecurityConstraint sc2 = new SecurityConstraint();
         // do not add a role - which signals access permitted without one
         sc2.addCollection(collection2);
@@ -430,9 +430,9 @@ public class TestNonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet to the context
         Tomcat.addServlet(basicContext, "TesterServlet3", new TesterServlet());
-        basicContext.addServletMappingDecoded(URI_PROTECTED, "TesterServlet3");
+        basicContext.addServletMapping(URI_PROTECTED, "TesterServlet3");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI_PROTECTED);
+        collection.addPattern(URI_PROTECTED);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
         sc.addCollection(collection);
@@ -440,10 +440,10 @@ public class TestNonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add unprotected servlet to the context
         Tomcat.addServlet(basicContext, "TesterServlet4", new TesterServlet());
-        basicContext.addServletMappingDecoded(URI_PUBLIC, "TesterServlet4");
+        basicContext.addServletMapping(URI_PUBLIC, "TesterServlet4");
 
         SecurityCollection collection2 = new SecurityCollection();
-        collection2.addPatternDecoded(URI_PUBLIC);
+        collection2.addPattern(URI_PUBLIC);
         SecurityConstraint sc2 = new SecurityConstraint();
         // do not add a role - which signals access permitted without one
         sc2.addCollection(collection2);
diff --git a/test/org/apache/catalina/authenticator/TestSSOChangeSessionId.java b/test/org/apache/catalina/authenticator/TestSSOChangeSessionId.java
index 6919cd1e8d..3f6d9c9c1a 100644
--- a/test/org/apache/catalina/authenticator/TestSSOChangeSessionId.java
+++ b/test/org/apache/catalina/authenticator/TestSSOChangeSessionId.java
@@ -92,10 +92,10 @@ public class TestSSOChangeSessionId extends TomcatBaseTest {
 
         // Add protected servlet to the context
         Tomcat.addServlet(testContext, "TesterServlet1", new TesterServlet());
-        testContext.addServletMappingDecoded(URI_PROTECTED, "TesterServlet1");
+        testContext.addServletMapping(URI_PROTECTED, "TesterServlet1");
 
         SecurityCollection collection1 = new SecurityCollection();
-        collection1.addPatternDecoded(URI_PROTECTED);
+        collection1.addPattern(URI_PROTECTED);
         SecurityConstraint sc1 = new SecurityConstraint();
         sc1.addAuthRole(ROLE);
         sc1.addCollection(collection1);
@@ -103,10 +103,10 @@ public class TestSSOChangeSessionId extends TomcatBaseTest {
 
         // Add Authenticator
         Tomcat.addServlet(testContext, "LoginServlet", new LoginServlet());
-        testContext.addServletMappingDecoded(URI_AUTHENTICATION, "LoginServlet");
+        testContext.addServletMapping(URI_AUTHENTICATION, "LoginServlet");
 
         SecurityCollection collection2 = new SecurityCollection();
-        collection2.addPatternDecoded(URI_AUTHENTICATION);
+        collection2.addPattern(URI_AUTHENTICATION);
         SecurityConstraint sc2 = new SecurityConstraint();
         // do not add a role - which signals access permitted without one
         sc2.addCollection(collection2);
diff --git a/test/org/apache/catalina/authenticator/TestSSOnonLoginAndBasicAuthenticator.java b/test/org/apache/catalina/authenticator/TestSSOnonLoginAndBasicAuthenticator.java
index 87092f9c23..8a66aa3612 100644
--- a/test/org/apache/catalina/authenticator/TestSSOnonLoginAndBasicAuthenticator.java
+++ b/test/org/apache/catalina/authenticator/TestSSOnonLoginAndBasicAuthenticator.java
@@ -407,10 +407,10 @@ public class TestSSOnonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet to the context
         Tomcat.addServlet(nonloginContext, "TesterServlet1", new TesterServletEncodeUrl());
-        nonloginContext.addServletMappingDecoded(URI_PROTECTED, "TesterServlet1");
+        nonloginContext.addServletMapping(URI_PROTECTED, "TesterServlet1");
 
         SecurityCollection collection1 = new SecurityCollection();
-        collection1.addPatternDecoded(URI_PROTECTED);
+        collection1.addPattern(URI_PROTECTED);
         SecurityConstraint sc1 = new SecurityConstraint();
         sc1.addAuthRole(ROLE);
         sc1.addCollection(collection1);
@@ -418,10 +418,10 @@ public class TestSSOnonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add unprotected servlet to the context
         Tomcat.addServlet(nonloginContext, "TesterServlet2", new TesterServletEncodeUrl());
-        nonloginContext.addServletMappingDecoded(URI_PUBLIC, "TesterServlet2");
+        nonloginContext.addServletMapping(URI_PUBLIC, "TesterServlet2");
 
         SecurityCollection collection2 = new SecurityCollection();
-        collection2.addPatternDecoded(URI_PUBLIC);
+        collection2.addPattern(URI_PUBLIC);
         SecurityConstraint sc2 = new SecurityConstraint();
         // do not add a role - which signals access permitted without one
         sc2.addCollection(collection2);
@@ -443,9 +443,9 @@ public class TestSSOnonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet to the context
         Tomcat.addServlet(basicContext, "TesterServlet3", new TesterServletEncodeUrl());
-        basicContext.addServletMappingDecoded(URI_PROTECTED, "TesterServlet3");
+        basicContext.addServletMapping(URI_PROTECTED, "TesterServlet3");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI_PROTECTED);
+        collection.addPattern(URI_PROTECTED);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
         sc.addCollection(collection);
@@ -453,9 +453,9 @@ public class TestSSOnonLoginAndBasicAuthenticator extends TomcatBaseTest {
 
         // Add unprotected servlet to the context
         Tomcat.addServlet(basicContext, "TesterServlet4", new TesterServletEncodeUrl());
-        basicContext.addServletMappingDecoded(URI_PUBLIC, "TesterServlet4");
+        basicContext.addServletMapping(URI_PUBLIC, "TesterServlet4");
         SecurityCollection collection2 = new SecurityCollection();
-        collection2.addPatternDecoded(URI_PUBLIC);
+        collection2.addPattern(URI_PUBLIC);
         SecurityConstraint sc2 = new SecurityConstraint();
         // do not add a role - which signals access permitted without one
         sc2.addCollection(collection2);
diff --git a/test/org/apache/catalina/authenticator/TestSSOnonLoginAndDigestAuthenticator.java b/test/org/apache/catalina/authenticator/TestSSOnonLoginAndDigestAuthenticator.java
index dffb97ad2c..659dd3b4b0 100644
--- a/test/org/apache/catalina/authenticator/TestSSOnonLoginAndDigestAuthenticator.java
+++ b/test/org/apache/catalina/authenticator/TestSSOnonLoginAndDigestAuthenticator.java
@@ -276,9 +276,9 @@ public class TestSSOnonLoginAndDigestAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctxt, "TesterServlet1", new TesterServlet());
-        ctxt.addServletMappingDecoded(URI_PROTECTED, "TesterServlet1");
+        ctxt.addServletMapping(URI_PROTECTED, "TesterServlet1");
         SecurityCollection collection1 = new SecurityCollection();
-        collection1.addPatternDecoded(URI_PROTECTED);
+        collection1.addPattern(URI_PROTECTED);
         SecurityConstraint sc1 = new SecurityConstraint();
         sc1.addAuthRole(ROLE);
         sc1.addCollection(collection1);
@@ -286,9 +286,9 @@ public class TestSSOnonLoginAndDigestAuthenticator extends TomcatBaseTest {
 
         // Add unprotected servlet
         Tomcat.addServlet(ctxt, "TesterServlet2", new TesterServlet());
-        ctxt.addServletMappingDecoded(URI_PUBLIC, "TesterServlet2");
+        ctxt.addServletMapping(URI_PUBLIC, "TesterServlet2");
         SecurityCollection collection2 = new SecurityCollection();
-        collection2.addPatternDecoded(URI_PUBLIC);
+        collection2.addPattern(URI_PUBLIC);
         SecurityConstraint sc2 = new SecurityConstraint();
         // do not add a role - which signals access permitted without one
         sc2.addCollection(collection2);
@@ -309,9 +309,9 @@ public class TestSSOnonLoginAndDigestAuthenticator extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctxt, "TesterServlet3", new TesterServlet());
-        ctxt.addServletMappingDecoded(URI_PROTECTED, "TesterServlet3");
+        ctxt.addServletMapping(URI_PROTECTED, "TesterServlet3");
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI_PROTECTED);
+        collection.addPattern(URI_PROTECTED);
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
         sc.addCollection(collection);
diff --git a/test/org/apache/catalina/connector/TestClientReadTimeout.java b/test/org/apache/catalina/connector/TestClientReadTimeout.java
index 8c25542675..38170718a8 100644
--- a/test/org/apache/catalina/connector/TestClientReadTimeout.java
+++ b/test/org/apache/catalina/connector/TestClientReadTimeout.java
@@ -55,7 +55,7 @@ public class TestClientReadTimeout extends TomcatBaseTest {
         ((StandardHost) tomcat.getHost()).setErrorReportValveClass(null);
 
         Tomcat.addServlet(ctx, "TestServlet", new SyncServlet());
-        ctx.addServletMappingDecoded("/*", "TestServlet");
+        ctx.addServletMapping("/*", "TestServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestConnector.java b/test/org/apache/catalina/connector/TestConnector.java
index 9cd2c7df6f..1efb7529fa 100644
--- a/test/org/apache/catalina/connector/TestConnector.java
+++ b/test/org/apache/catalina/connector/TestConnector.java
@@ -50,7 +50,7 @@ public class TestConnector extends TomcatBaseTest {
         Context root = tomcat.addContext("", TEMP_DIR);
         Wrapper w = Tomcat.addServlet(root, "tester", new TesterServlet());
         w.setAsyncSupported(true);
-        root.addServletMappingDecoded("/", "tester");
+        root.addServletMapping("/", "tester");
 
         Connector connector = tomcat.getConnector();
 
@@ -188,7 +188,7 @@ public class TestConnector extends TomcatBaseTest {
         File appDir = new File("test/webapp");
         Context root = tomcat.addContext("", appDir.getAbsolutePath());
         Tomcat.addServlet(root, "default", servlet);
-        root.addServletMappingDecoded("/", "default");
+        root.addServletMapping("/", "default");
 
         Connector connector = tomcat.getConnector();
         connector.setAllowTrace(allowTrace);
@@ -236,7 +236,7 @@ public class TestConnector extends TomcatBaseTest {
 
         Context root = getProgrammaticRootContext();
         Tomcat.addServlet(root, "default", new TesterServlet());
-        root.addServletMappingDecoded("/", "default");
+        root.addServletMapping("/", "default");
 
         Connector connector = tomcat.getConnector();
         connector.setAllowBackslash(true);
diff --git a/test/org/apache/catalina/connector/TestCoyoteAdapter.java b/test/org/apache/catalina/connector/TestCoyoteAdapter.java
index 8c5ffe48cd..73604ab19b 100644
--- a/test/org/apache/catalina/connector/TestCoyoteAdapter.java
+++ b/test/org/apache/catalina/connector/TestCoyoteAdapter.java
@@ -117,7 +117,7 @@ public class TestCoyoteAdapter extends TomcatBaseTest {
         Context ctx = tomcat.addContext("", docBase.getAbsolutePath());
 
         Tomcat.addServlet(ctx, "servlet", new PathParamServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -138,7 +138,7 @@ public class TestCoyoteAdapter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new PathParamServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -189,7 +189,7 @@ public class TestCoyoteAdapter extends TomcatBaseTest {
         Context ctx = tomcat.addContext("/testapp", null);
 
         Tomcat.addServlet(ctx, "servlet", new PathParamServlet());
-        ctx.addServletMappingDecoded("*.txt", "servlet");
+        ctx.addServletMapping("*.txt", "servlet");
 
         tomcat.start();
 
@@ -239,7 +239,7 @@ public class TestCoyoteAdapter extends TomcatBaseTest {
 
         PathInfoServlet servlet = new PathInfoServlet();
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/*", "servlet");
+        ctx.addServletMapping("/*", "servlet");
 
         tomcat.start();
 
@@ -286,7 +286,7 @@ public class TestCoyoteAdapter extends TomcatBaseTest {
         AsyncServlet servlet = new AsyncServlet();
         Wrapper w = Tomcat.addServlet(ctx, "async", servlet);
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/async", "async");
+        ctx.addServletMapping("/async", "async");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestCoyoteAdapterCanonicalization.java b/test/org/apache/catalina/connector/TestCoyoteAdapterCanonicalization.java
index ef0d8cf9ab..9a20226b59 100644
--- a/test/org/apache/catalina/connector/TestCoyoteAdapterCanonicalization.java
+++ b/test/org/apache/catalina/connector/TestCoyoteAdapterCanonicalization.java
@@ -170,7 +170,7 @@ public class TestCoyoteAdapterCanonicalization extends TomcatBaseTest {
         // Map as default servlet so servlet path should be URI less context
         // path. Since the content path is "" the servlet path should be the
         // URI.
-        root.addServletMappingDecoded("/", "EchoServletPath");
+        root.addServletMapping("/", "EchoServletPath");
 
         if (specCompliant) {
             // Enabled options for stricter checking
diff --git a/test/org/apache/catalina/connector/TestCoyoteAdapterRequestFuzzing.java b/test/org/apache/catalina/connector/TestCoyoteAdapterRequestFuzzing.java
index f014340253..8592ace869 100644
--- a/test/org/apache/catalina/connector/TestCoyoteAdapterRequestFuzzing.java
+++ b/test/org/apache/catalina/connector/TestCoyoteAdapterRequestFuzzing.java
@@ -117,7 +117,7 @@ public class TestCoyoteAdapterRequestFuzzing extends TomcatBaseTest {
         File appDir = new File("test/webapp");
         Context ctxt = tomcat.addContext("", appDir.getAbsolutePath());
         Tomcat.addServlet(ctxt, "default", DefaultServlet.class.getName());
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestCoyoteInputStream.java b/test/org/apache/catalina/connector/TestCoyoteInputStream.java
index a6c9211174..6d91303239 100644
--- a/test/org/apache/catalina/connector/TestCoyoteInputStream.java
+++ b/test/org/apache/catalina/connector/TestCoyoteInputStream.java
@@ -41,7 +41,7 @@ public class TestCoyoteInputStream extends TomcatBaseTest {
 
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "testServlet", new TestServlet());
-        root.addServletMappingDecoded("/", "testServlet");
+        root.addServletMapping("/", "testServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestCoyoteOutputStream.java b/test/org/apache/catalina/connector/TestCoyoteOutputStream.java
index ad8f644c90..939b8c5973 100644
--- a/test/org/apache/catalina/connector/TestCoyoteOutputStream.java
+++ b/test/org/apache/catalina/connector/TestCoyoteOutputStream.java
@@ -109,7 +109,7 @@ public class TestCoyoteOutputStream extends TomcatBaseTest {
 
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "testServlet", new TestServlet());
-        root.addServletMappingDecoded("/", "testServlet");
+        root.addServletMapping("/", "testServlet");
 
         tomcat.start();
 
@@ -133,10 +133,10 @@ public class TestCoyoteOutputStream extends TomcatBaseTest {
         Wrapper w = Tomcat.addServlet(root, "nbWrite",
                 new NonBlockingWriteServlet(asyncWriteTarget, useContainerThreadToSetListener));
         w.setAsyncSupported(true);
-        root.addServletMappingDecoded("/nbWrite", "nbWrite");
+        root.addServletMapping("/nbWrite", "nbWrite");
         Tomcat.addServlet(root, "write", new BlockingWriteServlet(asyncWriteTarget, syncWriteTarget));
         w.setAsyncSupported(true);
-        root.addServletMappingDecoded("/write", "write");
+        root.addServletMapping("/write", "write");
 
         tomcat.start();
 
@@ -288,7 +288,7 @@ public class TestCoyoteOutputStream extends TomcatBaseTest {
 
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "servlet", new WriteAfterBodyCompleteServlet());
-        root.addServletMappingDecoded("/", "servlet");
+        root.addServletMapping("/", "servlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestInputBuffer.java b/test/org/apache/catalina/connector/TestInputBuffer.java
index b55213d585..55d3ad142f 100644
--- a/test/org/apache/catalina/connector/TestInputBuffer.java
+++ b/test/org/apache/catalina/connector/TestInputBuffer.java
@@ -46,7 +46,7 @@ public class TestInputBuffer extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "Echo", new Utf8Echo());
-        root.addServletMappingDecoded("/test", "Echo");
+        root.addServletMapping("/test", "Echo");
 
         tomcat.start();
 
@@ -65,7 +65,7 @@ public class TestInputBuffer extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "Bug60400Servlet", new Bug60400Servlet());
-        root.addServletMappingDecoded("/", "Bug60400Servlet");
+        root.addServletMapping("/", "Bug60400Servlet");
 
         Assert.assertTrue(tomcat.getConnector().setProperty("socket.appReadBufSize", "9000"));
         tomcat.start();
@@ -84,7 +84,7 @@ public class TestInputBuffer extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "Echo", new Utf8Echo());
-        root.addServletMappingDecoded("/test", "Echo");
+        root.addServletMapping("/test", "Echo");
 
         Assert.assertTrue(tomcat.getConnector().setProperty("socket.appReadBufSize", "10500"));
 
diff --git a/test/org/apache/catalina/connector/TestKeepAliveCount.java b/test/org/apache/catalina/connector/TestKeepAliveCount.java
index 582fbb1a1f..eaed5dc778 100644
--- a/test/org/apache/catalina/connector/TestKeepAliveCount.java
+++ b/test/org/apache/catalina/connector/TestKeepAliveCount.java
@@ -59,7 +59,7 @@ public class TestKeepAliveCount extends TomcatBaseTest {
             Tomcat tomcat = getTomcatInstance();
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "Simple", new SimpleServlet());
-            root.addServletMappingDecoded("/test", "Simple");
+            root.addServletMapping("/test", "Simple");
             Assert.assertTrue(tomcat.getConnector().setProperty("maxKeepAliveRequests", "5"));
             Assert.assertTrue(tomcat.getConnector().setProperty("connectionTimeout", "20000"));
             Assert.assertTrue(tomcat.getConnector().setProperty("keepAliveTimeout", "50000"));
diff --git a/test/org/apache/catalina/connector/TestMaxConnections.java b/test/org/apache/catalina/connector/TestMaxConnections.java
index 9af6fe2718..1cc9c5ef2d 100644
--- a/test/org/apache/catalina/connector/TestMaxConnections.java
+++ b/test/org/apache/catalina/connector/TestMaxConnections.java
@@ -73,7 +73,7 @@ public class TestMaxConnections extends TomcatBaseTest {
         StandardContext root = (StandardContext) tomcat.addContext("", SimpleHttpClient.TEMP_DIR);
         root.setUnloadDelay(soTimeout);
         Tomcat.addServlet(root, "Simple", new SimpleServlet());
-        root.addServletMappingDecoded("/test", "Simple");
+        root.addServletMapping("/test", "Simple");
         Assert.assertTrue(tomcat.getConnector().setProperty("maxKeepAliveRequests", "1"));
         Assert.assertTrue(tomcat.getConnector().setProperty("maxThreads", "10"));
         Assert.assertTrue(tomcat.getConnector().setProperty("connectionTimeout", "20000"));
diff --git a/test/org/apache/catalina/connector/TestOutputBuffer.java b/test/org/apache/catalina/connector/TestOutputBuffer.java
index d4c331f274..520154704b 100644
--- a/test/org/apache/catalina/connector/TestOutputBuffer.java
+++ b/test/org/apache/catalina/connector/TestOutputBuffer.java
@@ -51,7 +51,7 @@ public class TestOutputBuffer extends TomcatBaseTest {
         for (int i = 1; i <= WritingServlet.EXPECTED_CONTENT_LENGTH; i *= 10) {
             WritingServlet servlet = new WritingServlet(i);
             Tomcat.addServlet(root, "servlet" + i, servlet);
-            root.addServletMappingDecoded("/servlet" + i, "servlet" + i);
+            root.addServletMapping("/servlet" + i, "servlet" + i);
         }
 
         tomcat.start();
@@ -81,7 +81,7 @@ public class TestOutputBuffer extends TomcatBaseTest {
 
         Bug52577Servlet bug52577 = new Bug52577Servlet();
         Tomcat.addServlet(root, "bug52577", bug52577);
-        root.addServletMappingDecoded("/", "bug52577");
+        root.addServletMapping("/", "bug52577");
 
         tomcat.start();
 
@@ -168,7 +168,7 @@ public class TestOutputBuffer extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context root = tomcat.addContext("", TEMP_DIR);
         Tomcat.addServlet(root, "Test", new Utf8WriteChars(data));
-        root.addServletMappingDecoded("/test", "Test");
+        root.addServletMapping("/test", "Test");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestRequest.java b/test/org/apache/catalina/connector/TestRequest.java
index f2a1bbb5c6..30ff9f1252 100644
--- a/test/org/apache/catalina/connector/TestRequest.java
+++ b/test/org/apache/catalina/connector/TestRequest.java
@@ -147,7 +147,7 @@ public class TestRequest extends TomcatBaseTest {
             Tomcat tomcat = getTomcatInstance();
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "Bug37794", new Bug37794Servlet());
-            root.addServletMappingDecoded("/test", "Bug37794");
+            root.addServletMapping("/test", "Bug37794");
 
             tomcat.start();
 
@@ -241,7 +241,7 @@ public class TestRequest extends TomcatBaseTest {
 
         // Add the Servlet
         Tomcat.addServlet(ctx, "servlet", new EchoQueryStringServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -287,7 +287,7 @@ public class TestRequest extends TomcatBaseTest {
         ctx.getPipeline().addValve(new BasicAuthenticator());
 
         Tomcat.addServlet(ctx, "servlet", new LoginLogoutServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterMapRealm realm = new TesterMapRealm();
         realm.addUser(LoginLogoutServlet.USER, LoginLogoutServlet.PWD);
@@ -336,7 +336,7 @@ public class TestRequest extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context root = tomcat.addContext("", System.getProperty("java.io.tmpdir"));
         Tomcat.addServlet(root, "Bug37794", new Bug37794Servlet());
-        root.addServletMappingDecoded("/", "Bug37794");
+        root.addServletMapping("/", "Bug37794");
         tomcat.start();
 
         HttpURLConnection conn = getConnection("http://localhost:" + getPort() + "/");
@@ -349,7 +349,7 @@ public class TestRequest extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context root = tomcat.addContext("", System.getProperty("java.io.tmpdir"));
         Tomcat.addServlet(root, "Bug37794", new Bug37794Servlet());
-        root.addServletMappingDecoded("/", "Bug37794");
+        root.addServletMapping("/", "Bug37794");
         tomcat.start();
 
         HttpURLConnection conn = getConnection("http://localhost:" + getPort() + "/");
@@ -418,7 +418,7 @@ public class TestRequest extends TomcatBaseTest {
         Context root = tomcat.addContext("", System.getProperty("java.io.tmpdir"));
         root.setAllowCasualMultipartParsing(true);
         Tomcat.addServlet(root, "Bug54984", new Bug54984Servlet());
-        root.addServletMappingDecoded("/", "Bug54984");
+        root.addServletMapping("/", "Bug54984");
         tomcat.start();
 
         HttpURLConnection conn = getConnection("http://localhost:" + getPort() + "/parseParametersBeforeParseParts");
@@ -493,7 +493,7 @@ public class TestRequest extends TomcatBaseTest {
             Tomcat tomcat = getTomcatInstance();
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "EchoParameters", new EchoParametersServlet());
-            root.addServletMappingDecoded("/echo", "EchoParameters");
+            root.addServletMapping("/echo", "EchoParameters");
             tomcat.start();
 
             setPort(tomcat.getConnector().getLocalPort());
@@ -767,7 +767,7 @@ public class TestRequest extends TomcatBaseTest {
         ctx.setAllowMultipleLeadingForwardSlashInPath(true);
 
         Tomcat.addServlet(ctx, "servlet", new Bug56501Servlet());
-        ctx.addServletMappingDecoded("/*", "servlet");
+        ctx.addServletMapping("/*", "servlet");
 
         tomcat.start();
 
@@ -841,7 +841,7 @@ public class TestRequest extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new Bug61264GetReaderServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -912,7 +912,7 @@ public class TestRequest extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new Bug69442Servlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -953,7 +953,7 @@ public class TestRequest extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "Bug69690", new Bug69690Servlet());
-        ctx.addServletMappingDecoded("/", "Bug69690");
+        ctx.addServletMapping("/", "Bug69690");
         tomcat.start();
 
         HttpURLConnection conn = getConnection("http://localhost:" + getPort() + "/parameter?a=b");
@@ -987,7 +987,7 @@ public class TestRequest extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "Bug69690", new Bug69690Servlet());
-        ctx.addServletMappingDecoded("/", "Bug69690");
+        ctx.addServletMapping("/", "Bug69690");
         tomcat.start();
 
         HttpURLConnection conn = getConnection("http://localhost:" + getPort() + "/part?a=b");
diff --git a/test/org/apache/catalina/connector/TestResponse.java b/test/org/apache/catalina/connector/TestResponse.java
index d8cf0f1da9..f8c0b5c7b0 100644
--- a/test/org/apache/catalina/connector/TestResponse.java
+++ b/test/org/apache/catalina/connector/TestResponse.java
@@ -56,7 +56,7 @@ public class TestResponse extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new Bug49598Servlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -110,7 +110,7 @@ public class TestResponse extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new CharsetServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -148,7 +148,7 @@ public class TestResponse extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new Bug52811Servlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -971,7 +971,7 @@ public class TestResponse extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new ErrorPageServlet());
-        ctx.addServletMappingDecoded("/error", "servlet");
+        ctx.addServletMapping("/error", "servlet");
         ErrorPage servletErrorPage = new ErrorPage();
         servletErrorPage.setErrorCode(404);
         servletErrorPage.setLocation("/error");
diff --git a/test/org/apache/catalina/connector/TestSendFile.java b/test/org/apache/catalina/connector/TestSendFile.java
index 69979b5c3a..82ae639c68 100644
--- a/test/org/apache/catalina/connector/TestSendFile.java
+++ b/test/org/apache/catalina/connector/TestSendFile.java
@@ -66,7 +66,7 @@ public class TestSendFile extends TomcatBaseTest {
         for (int i = 0; i < ITERATIONS; i++) {
             WritingServlet servlet = new WritingServlet(files[i]);
             Tomcat.addServlet(root, "servlet" + i, servlet);
-            root.addServletMappingDecoded("/servlet" + i, "servlet" + i);
+            root.addServletMapping("/servlet" + i, "servlet" + i);
         }
 
         tomcat.start();
@@ -154,7 +154,7 @@ public class TestSendFile extends TomcatBaseTest {
         Context ctx = tomcat.addContext("", TEMP_DIR);
         File file = generateFile(TEMP_DIR, "", EXPECTED_CONTENT_LENGTH);
         Tomcat.addServlet(ctx, "test", new Bug60409Servlet(file));
-        ctx.addServletMappingDecoded("/", "test");
+        ctx.addServletMapping("/", "test");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/connector/TestValidateClientSessionId.java b/test/org/apache/catalina/connector/TestValidateClientSessionId.java
index dc94fc3fc3..61cba95f04 100644
--- a/test/org/apache/catalina/connector/TestValidateClientSessionId.java
+++ b/test/org/apache/catalina/connector/TestValidateClientSessionId.java
@@ -37,7 +37,7 @@ public class TestValidateClientSessionId extends TomcatBaseTest {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/", "snoop");
+        ctx.addServletMapping("/", "snoop");
 
         tomcat.start();
 
@@ -60,12 +60,12 @@ public class TestValidateClientSessionId extends TomcatBaseTest {
         Context ctx1 = tomcat.addContext("/app1", null);
         ctx1.setSessionCookiePath("/");
         Tomcat.addServlet(ctx1, "snoop", new SnoopServlet());
-        ctx1.addServletMappingDecoded("/", "snoop");
+        ctx1.addServletMapping("/", "snoop");
 
         Context ctx2 = tomcat.addContext("/app2", null);
         ctx2.setSessionCookiePath("/");
         Tomcat.addServlet(ctx2, "snoop", new SnoopServlet());
-        ctx2.addServletMappingDecoded("/", "snoop");
+        ctx2.addServletMapping("/", "snoop");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestApplicationContext.java b/test/org/apache/catalina/core/TestApplicationContext.java
index 108e2a4600..95364591eb 100644
--- a/test/org/apache/catalina/core/TestApplicationContext.java
+++ b/test/org/apache/catalina/core/TestApplicationContext.java
@@ -182,7 +182,7 @@ public class TestApplicationContext extends TomcatBaseTest {
         ctx.setCrossContext(true);
 
         Tomcat.addServlet(ctx, "Bug57190Servlet", new Bug57190Servlet());
-        ctx.addServletMappingDecoded("/", "Bug57190Servlet");
+        ctx.addServletMapping("/", "Bug57190Servlet");
 
         tomcat.start();
 
@@ -253,14 +253,14 @@ public class TestApplicationContext extends TomcatBaseTest {
         Context ctx2 = tomcat.addContext("/second", null);
         GetAttributeServlet getAttributeServlet = new GetAttributeServlet();
         Tomcat.addServlet(ctx2, "getAttributeServlet", getAttributeServlet);
-        ctx2.addServletMappingDecoded("/test", "getAttributeServlet");
+        ctx2.addServletMapping("/test", "getAttributeServlet");
 
         // No file system docBase required
         Context ctx1 = tomcat.addContext("/first", null);
         ctx1.setCrossContext(true);
         SetAttributeServlet setAttributeServlet = new SetAttributeServlet("/test", "/second");
         Tomcat.addServlet(ctx1, "setAttributeServlet", setAttributeServlet);
-        ctx1.addServletMappingDecoded("/test", "setAttributeServlet");
+        ctx1.addServletMapping("/test", "setAttributeServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcher.java b/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcher.java
index 0ea509ec25..06574bd6d7 100644
--- a/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcher.java
+++ b/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcher.java
@@ -361,11 +361,11 @@ public class TestApplicationContextGetRequestDispatcher extends TomcatBaseTest {
 
         // Add a default servlet to return 404 for not found resources
         Tomcat.addServlet(ctx, "Default", new Default404Servlet());
-        ctx.addServletMappingDecoded("/", "Default");
+        ctx.addServletMapping("/", "Default");
 
         // Add a target servlet to dispatch to
         Tomcat.addServlet(ctx, "target", new TargetServlet());
-        ctx.addServletMappingDecoded(UDecoder.URLDecode(targetPath, StandardCharsets.UTF_8), "target");
+        ctx.addServletMapping(UDecoder.URLDecode(targetPath, StandardCharsets.UTF_8), "target");
 
         if (useAsync) {
             Wrapper w = Tomcat.addServlet(ctx, "rd", new AsyncDispatcherServlet(dispatchPath, useEncodedDispatchPaths));
@@ -373,7 +373,7 @@ public class TestApplicationContextGetRequestDispatcher extends TomcatBaseTest {
         } else {
             Tomcat.addServlet(ctx, "rd", new DispatcherServlet(dispatchPath));
         }
-        ctx.addServletMappingDecoded(UDecoder.URLDecode(startPath, StandardCharsets.UTF_8), "rd");
+        ctx.addServletMapping(UDecoder.URLDecode(startPath, StandardCharsets.UTF_8), "rd");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherB.java b/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherB.java
index fd48eb900d..257195dc4a 100644
--- a/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherB.java
+++ b/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherB.java
@@ -333,11 +333,11 @@ public class TestApplicationContextGetRequestDispatcherB extends TomcatBaseTest
 
         // Add a target servlet to dispatch to
         Tomcat.addServlet(ctx, "target", new Target());
-        ctx.addServletMappingDecoded(targetMapping, "target");
+        ctx.addServletMapping(targetMapping, "target");
 
         Wrapper w = Tomcat.addServlet(ctx, "rd", new Dispatch());
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded(startMapping, "rd");
+        ctx.addServletMapping(startMapping, "rd");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherC.java b/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherC.java
index c1c6832927..eddbb5c3fc 100644
--- a/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherC.java
+++ b/test/org/apache/catalina/core/TestApplicationContextGetRequestDispatcherC.java
@@ -97,11 +97,11 @@ public class TestApplicationContextGetRequestDispatcherC extends TomcatBaseTest
 
         // Servlet that performs a dispatch to ...
         Tomcat.addServlet(ctx, "rd", new Dispatch(pathInfoRequest));
-        ctx.addServletMappingDecoded("/dispatch/*", "rd");
+        ctx.addServletMapping("/dispatch/*", "rd");
 
         // ... this Servlet
         Tomcat.addServlet(ctx, "target", new Target());
-        ctx.addServletMappingDecoded("/target/*", "target");
+        ctx.addServletMapping("/target/*", "target");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestApplicationDispatcher.java b/test/org/apache/catalina/core/TestApplicationDispatcher.java
index d1fa2dc799..1933e4a01f 100644
--- a/test/org/apache/catalina/core/TestApplicationDispatcher.java
+++ b/test/org/apache/catalina/core/TestApplicationDispatcher.java
@@ -47,10 +47,10 @@ public class TestApplicationDispatcher extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "errorTrigger", new ErrorTriggerServlet());
-        ctx.addServletMappingDecoded("/trigger", "errorTrigger");
+        ctx.addServletMapping("/trigger", "errorTrigger");
 
         Tomcat.addServlet(ctx, "errorHandling", new ErrorHandlingServlet());
-        ctx.addServletMappingDecoded("/error", "errorHandling");
+        ctx.addServletMapping("/error", "errorHandling");
 
         ErrorPage ep = new ErrorPage();
         ep.setExceptionType(Throwable.class.getName());
@@ -86,7 +86,7 @@ public class TestApplicationDispatcher extends TomcatBaseTest {
         Context ctx = (Context) tomcat.getHost().findChildren()[0];
 
         Tomcat.addServlet(ctx, "errorHandling", new ErrorHandlingServlet());
-        ctx.addServletMappingDecoded("/error", "errorHandling");
+        ctx.addServletMapping("/error", "errorHandling");
 
         ErrorPage ep = new ErrorPage();
         ep.setExceptionType(Throwable.class.getName());
diff --git a/test/org/apache/catalina/core/TestApplicationFilterConfig.java b/test/org/apache/catalina/core/TestApplicationFilterConfig.java
index 22aa2a0334..5452737ec0 100644
--- a/test/org/apache/catalina/core/TestApplicationFilterConfig.java
+++ b/test/org/apache/catalina/core/TestApplicationFilterConfig.java
@@ -41,7 +41,7 @@ public class TestApplicationFilterConfig extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "HelloWorld", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "HelloWorld");
+        ctx.addServletMapping("/", "HelloWorld");
 
         // Add a filter with a name that should be escaped if used in a JMX
         // object name
diff --git a/test/org/apache/catalina/core/TestApplicationHttpRequest.java b/test/org/apache/catalina/core/TestApplicationHttpRequest.java
index 23bc4bc152..c74fe2fa09 100644
--- a/test/org/apache/catalina/core/TestApplicationHttpRequest.java
+++ b/test/org/apache/catalina/core/TestApplicationHttpRequest.java
@@ -192,10 +192,10 @@ public class TestApplicationHttpRequest extends TomcatBaseTest {
         } else {
             Tomcat.addServlet(ctx, "forward", new ForwardServlet("/display?" + forwardQueryString));
         }
-        ctx.addServletMappingDecoded("/forward", "forward");
+        ctx.addServletMapping("/forward", "forward");
 
         Tomcat.addServlet(ctx, "display", new DisplayParameterServlet(expected));
-        ctx.addServletMappingDecoded("/display", "display");
+        ctx.addServletMapping("/display", "display");
 
         tomcat.start();
 
@@ -247,10 +247,10 @@ public class TestApplicationHttpRequest extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "forward", new ForwardServlet("/modify"));
-        ctx.addServletMappingDecoded("/forward", "forward");
+        ctx.addServletMapping("/forward", "forward");
 
         Tomcat.addServlet(ctx, "modify", new ModifyParameterServlet());
-        ctx.addServletMappingDecoded("/modify", "modify");
+        ctx.addServletMapping("/modify", "modify");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestApplicationMapping.java b/test/org/apache/catalina/core/TestApplicationMapping.java
index 98ff63b884..078e8a609f 100644
--- a/test/org/apache/catalina/core/TestApplicationMapping.java
+++ b/test/org/apache/catalina/core/TestApplicationMapping.java
@@ -126,7 +126,7 @@ public class TestApplicationMapping extends TomcatBaseTest {
         Context ctx = tomcat.addContext(contextPath, null);
 
         Tomcat.addServlet(ctx, "Mapping", new MappingServlet());
-        ctx.addServletMappingDecoded(mapping, "Mapping");
+        ctx.addServletMapping(mapping, "Mapping");
 
         tomcat.start();
 
@@ -147,9 +147,9 @@ public class TestApplicationMapping extends TomcatBaseTest {
         Context ctx = tomcat.addContext(contextPath, null);
 
         Tomcat.addServlet(ctx, "Include", new IncludeServlet());
-        ctx.addServletMappingDecoded(mapping, "Include");
+        ctx.addServletMapping(mapping, "Include");
         Tomcat.addServlet(ctx, "Mapping", new MappingServlet());
-        ctx.addServletMappingDecoded("/mapping", "Mapping");
+        ctx.addServletMapping("/mapping", "Mapping");
 
         tomcat.start();
 
@@ -175,9 +175,9 @@ public class TestApplicationMapping extends TomcatBaseTest {
         Context ctx = tomcat.addContext(contextPath, null);
 
         Tomcat.addServlet(ctx, "Include", new NamedIncludeServlet());
-        ctx.addServletMappingDecoded(mapping, "Include");
+        ctx.addServletMapping(mapping, "Include");
         Tomcat.addServlet(ctx, "Mapping", new MappingServlet());
-        ctx.addServletMappingDecoded("/mapping", "Mapping");
+        ctx.addServletMapping("/mapping", "Mapping");
 
         tomcat.start();
 
@@ -198,9 +198,9 @@ public class TestApplicationMapping extends TomcatBaseTest {
         Context ctx = tomcat.addContext(contextPath, null);
 
         Tomcat.addServlet(ctx, "Forward", new ForwardServlet());
-        ctx.addServletMappingDecoded(mapping, "Forward");
+        ctx.addServletMapping(mapping, "Forward");
         Tomcat.addServlet(ctx, "Mapping", new MappingServlet());
-        ctx.addServletMappingDecoded("/mapping", "Mapping");
+        ctx.addServletMapping("/mapping", "Mapping");
 
         tomcat.start();
 
@@ -226,9 +226,9 @@ public class TestApplicationMapping extends TomcatBaseTest {
         Context ctx = tomcat.addContext(contextPath, null);
 
         Tomcat.addServlet(ctx, "Forward", new NamedForwardServlet());
-        ctx.addServletMappingDecoded(mapping, "Forward");
+        ctx.addServletMapping(mapping, "Forward");
         Tomcat.addServlet(ctx, "Mapping", new MappingServlet());
-        ctx.addServletMappingDecoded("/mapping", "Mapping");
+        ctx.addServletMapping("/mapping", "Mapping");
 
         tomcat.start();
 
@@ -250,9 +250,9 @@ public class TestApplicationMapping extends TomcatBaseTest {
 
         Wrapper w = Tomcat.addServlet(ctx, "Async", new AsyncServlet());
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded(mapping, "Async");
+        ctx.addServletMapping(mapping, "Async");
         Tomcat.addServlet(ctx, "Mapping", new MappingServlet());
-        ctx.addServletMappingDecoded("/mapping", "Mapping");
+        ctx.addServletMapping("/mapping", "Mapping");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestAsyncContextImpl.java b/test/org/apache/catalina/core/TestAsyncContextImpl.java
index a5d9dcd7cd..6bdf666274 100644
--- a/test/org/apache/catalina/core/TestAsyncContextImpl.java
+++ b/test/org/apache/catalina/core/TestAsyncContextImpl.java
@@ -106,7 +106,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -143,7 +143,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -184,7 +184,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -220,7 +220,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -496,18 +496,18 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "time", timeout);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/start", "time");
+        ctx.addServletMapping("/start", "time");
 
         if (asyncDispatch != null) {
             if (asyncDispatch.booleanValue()) {
                 AsyncStartRunnable asyncStartRunnable = new AsyncStartRunnable();
                 Wrapper async = Tomcat.addServlet(ctx, "async", asyncStartRunnable);
                 async.setAsyncSupported(true);
-                ctx.addServletMappingDecoded(dispatchUrl, "async");
+                ctx.addServletMapping(dispatchUrl, "async");
             } else {
                 NonAsyncServlet nonAsync = new NonAsyncServlet();
                 Tomcat.addServlet(ctx, "nonasync", nonAsync);
-                ctx.addServletMappingDecoded(dispatchUrl, "nonasync");
+                ctx.addServletMapping(dispatchUrl, "nonasync");
             }
         }
 
@@ -654,12 +654,12 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         DispatchingServlet dispatch = new DispatchingServlet(false, false);
         Wrapper wrapper = Tomcat.addServlet(ctx, "dispatch", dispatch);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage1", "dispatch");
+        ctx.addServletMapping("/stage1", "dispatch");
 
         NonAsyncServlet nonasync = new NonAsyncServlet();
         Wrapper wrapper2 = Tomcat.addServlet(ctx, "nonasync", nonasync);
         wrapper2.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage2", "nonasync");
+        ctx.addServletMapping("/stage2", "nonasync");
 
         ctx.addApplicationListener(TrackingRequestListener.class.getName());
 
@@ -777,12 +777,12 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         TrackingServlet tracking = new TrackingServlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "tracking", tracking);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage1", "tracking");
+        ctx.addServletMapping("/stage1", "tracking");
 
         TimeoutServlet timeout = new TimeoutServlet(Boolean.TRUE, null);
         Wrapper wrapper2 = Tomcat.addServlet(ctx, "timeout", timeout);
         wrapper2.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage2", "timeout");
+        ctx.addServletMapping("/stage2", "timeout");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -1009,11 +1009,11 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         DispatchingServlet dispatch = new DispatchingServlet(true, completeOnError);
         Wrapper wrapper = Tomcat.addServlet(ctx, "dispatch", dispatch);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage1", "dispatch");
+        ctx.addServletMapping("/stage1", "dispatch");
 
         ErrorServlet error = new ErrorServlet();
         Tomcat.addServlet(ctx, "error", error);
-        ctx.addServletMappingDecoded("/stage2", "error");
+        ctx.addServletMapping("/stage2", "error");
 
         ctx.addApplicationListener(TrackingRequestListener.class.getName());
 
@@ -1087,7 +1087,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         AsyncStartRunnable servlet = new AsyncStartRunnable();
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -1153,7 +1153,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -1213,7 +1213,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         ErrorServlet error = new ErrorServlet();
         Tomcat.addServlet(ctx, "error", error);
-        ctx.addServletMappingDecoded("/error", "error");
+        ctx.addServletMapping("/error", "error");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -1248,7 +1248,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         AsyncStatusServlet asyncStatusServlet = new AsyncStatusServlet(HttpServletResponse.SC_BAD_REQUEST);
         Wrapper wrapper = Tomcat.addServlet(ctx, "asyncStatusServlet", asyncStatusServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/asyncStatusServlet", "asyncStatusServlet");
+        ctx.addServletMapping("/asyncStatusServlet", "asyncStatusServlet");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -1322,12 +1322,12 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         AsyncErrorServlet asyncErrorServlet = new AsyncErrorServlet(HttpServletResponse.SC_BAD_REQUEST, threaded);
         Wrapper wrapper = Tomcat.addServlet(ctx, "asyncErrorServlet", asyncErrorServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/asyncErrorServlet", "asyncErrorServlet");
+        ctx.addServletMapping("/asyncErrorServlet", "asyncErrorServlet");
 
         if (customError) {
             CustomErrorServlet customErrorServlet = new CustomErrorServlet();
             Tomcat.addServlet(ctx, "customErrorServlet", customErrorServlet);
-            ctx.addServletMappingDecoded("/customErrorServlet", "customErrorServlet");
+            ctx.addServletMapping("/customErrorServlet", "customErrorServlet");
 
             ErrorPage ep = new ErrorPage();
             ep.setLocation("/customErrorServlet");
@@ -1437,9 +1437,9 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         Wrapper b = Tomcat.addServlet(ctx, "ServletB", new Bug53337ServletB());
         b.setAsyncSupported(true);
         Tomcat.addServlet(ctx, "ServletC", new Bug53337ServletC());
-        ctx.addServletMappingDecoded("/ServletA", "ServletA");
-        ctx.addServletMappingDecoded("/ServletB", "ServletB");
-        ctx.addServletMappingDecoded("/ServletC", "ServletC");
+        ctx.addServletMapping("/ServletA", "ServletA");
+        ctx.addServletMapping("/ServletB", "ServletB");
+        ctx.addServletMapping("/ServletC", "ServletC");
 
         tomcat.start();
 
@@ -1514,8 +1514,8 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         a.setAsyncSupported(true);
         Tomcat.addServlet(ctx, "ServletB", new Bug53843ServletB());
 
-        ctx.addServletMappingDecoded("/ServletA", "ServletA");
-        ctx.addServletMappingDecoded("/ServletB", "ServletB");
+        ctx.addServletMapping("/ServletA", "ServletA");
+        ctx.addServletMapping("/ServletB", "ServletB");
 
         tomcat.start();
 
@@ -1621,17 +1621,17 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         TimeoutServlet timeout = new TimeoutServlet(null, null);
         Wrapper w1 = Tomcat.addServlet(ctx, "time", timeout);
         w1.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/async", "time");
+        ctx.addServletMapping("/async", "time");
 
         NonAsyncServlet nonAsync = new NonAsyncServlet();
         Wrapper w2 = Tomcat.addServlet(ctx, "nonAsync", nonAsync);
         w2.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/error/nonasync", "nonAsync");
+        ctx.addServletMapping("/error/nonasync", "nonAsync");
 
         AsyncErrorPage asyncErrorPage = new AsyncErrorPage(mode);
         Wrapper w3 = Tomcat.addServlet(ctx, "asyncErrorPage", asyncErrorPage);
         w3.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/error/async", "asyncErrorPage");
+        ctx.addServletMapping("/error/async", "asyncErrorPage");
 
         if (asyncError != null) {
             ErrorPage ep = new ErrorPage();
@@ -1747,11 +1747,11 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         Bug54178ServletA bug54178ServletA = new Bug54178ServletA();
         Wrapper wrapper = Tomcat.addServlet(ctx, "bug54178ServletA", bug54178ServletA);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/bug54178ServletA", "bug54178ServletA");
+        ctx.addServletMapping("/bug54178ServletA", "bug54178ServletA");
 
         Bug54178ServletB bug54178ServletB = new Bug54178ServletB();
         Tomcat.addServlet(ctx, "bug54178ServletB", bug54178ServletB);
-        ctx.addServletMappingDecoded("/bug54178ServletB", "bug54178ServletB");
+        ctx.addServletMapping("/bug54178ServletB", "bug54178ServletB");
 
         tomcat.start();
 
@@ -1854,7 +1854,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         Bug59219Servlet bug59219Servlet = new Bug59219Servlet();
         Wrapper w = tomcat.addServlet("", "async", bug59219Servlet);
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/async", "async");
+        ctx.addServletMapping("/async", "async");
 
         tomcat.start();
 
@@ -1917,12 +1917,12 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         NonAsyncServlet nonAsyncServlet = new NonAsyncServlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "nonAsyncServlet", nonAsyncServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/target", "nonAsyncServlet");
+        ctx.addServletMapping("/target", "nonAsyncServlet");
 
         DispatchingGenericServlet forbiddenDispatchingServlet = new DispatchingGenericServlet();
         Wrapper wrapper1 = Tomcat.addServlet(ctx, "forbiddenDispatchingServlet", forbiddenDispatchingServlet);
         wrapper1.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/forbiddenDispatchingServlet", "forbiddenDispatchingServlet");
+        ctx.addServletMapping("/forbiddenDispatchingServlet", "forbiddenDispatchingServlet");
 
         tomcat.start();
 
@@ -2001,7 +2001,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         Wrapper w = Tomcat.addServlet(ctx, "AsyncISEServlet", servlet);
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/test", "AsyncISEServlet");
+        ctx.addServletMapping("/test", "AsyncISEServlet");
 
         tomcat.start();
 
@@ -2118,12 +2118,12 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         DispatchingGenericServlet dispatch = new DispatchingGenericServlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "dispatch", dispatch);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/dispatch", "dispatch");
+        ctx.addServletMapping("/dispatch", "dispatch");
 
         CustomGenericServlet customGeneric = new CustomGenericServlet();
         Wrapper wrapper2 = Tomcat.addServlet(ctx, "customGeneric", customGeneric);
         wrapper2.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/target", "customGeneric");
+        ctx.addServletMapping("/target", "customGeneric");
 
         tomcat.start();
     }
@@ -2158,16 +2158,16 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         Servlet stage1 = new DispatchingServletTracking("/stage2", true);
         Wrapper wrapper1 = Tomcat.addServlet(ctx, "stage1", stage1);
         wrapper1.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage1", "stage1");
+        ctx.addServletMapping("/stage1", "stage1");
 
         Servlet stage2 = new DispatchingServletTracking("/stage3", false);
         Wrapper wrapper2 = Tomcat.addServlet(ctx, "stage2", stage2);
         wrapper2.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/stage2", "stage2");
+        ctx.addServletMapping("/stage2", "stage2");
 
         Servlet stage3 = new NonAsyncServlet();
         Tomcat.addServlet(ctx, "stage3", stage3);
-        ctx.addServletMappingDecoded("/stage3", "stage3");
+        ctx.addServletMapping("/stage3", "stage3");
 
         TesterAccessLogValve alv = new TesterAccessLogValve();
         ctx.getPipeline().addValve(alv);
@@ -2231,7 +2231,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         Servlet servlet = new AsyncRequestUriServlet();
         Wrapper wrapper1 = Tomcat.addServlet(ctx, "bug57559", servlet);
         wrapper1.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "bug57559");
+        ctx.addServletMapping("/", "bug57559");
 
         tomcat.start();
 
@@ -2268,17 +2268,17 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
 
         NonAsyncServlet nonAsyncServlet = new NonAsyncServlet();
         Tomcat.addServlet(ctx, "nonAsyncServlet", nonAsyncServlet);
-        ctx.addServletMappingDecoded("/target", "nonAsyncServlet");
+        ctx.addServletMapping("/target", "nonAsyncServlet");
 
         AsyncStashServlet asyncStashServlet = new AsyncStashServlet();
         Wrapper w1 = Tomcat.addServlet(ctx, "asyncStashServlet", asyncStashServlet);
         w1.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/asyncStashServlet", "asyncStashServlet");
+        ctx.addServletMapping("/asyncStashServlet", "asyncStashServlet");
 
         AsyncRetrieveServlet asyncRetrieveServlet = new AsyncRetrieveServlet();
         Wrapper w2 = Tomcat.addServlet(ctx, "asyncRetrieveServlet", asyncRetrieveServlet);
         w2.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/asyncRetrieveServlet", "asyncRetrieveServlet");
+        ctx.addServletMapping("/asyncRetrieveServlet", "asyncRetrieveServlet");
 
         tomcat.start();
 
@@ -2367,8 +2367,8 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         tomcat.addServlet("", "timeout", Bug58751AsyncServlet.class.getName()).setAsyncSupported(true);
         CustomErrorServlet customErrorServlet = new CustomErrorServlet();
         Tomcat.addServlet(context, "customErrorServlet", customErrorServlet);
-        context.addServletMappingDecoded("/timeout", "timeout");
-        context.addServletMappingDecoded("/error", "customErrorServlet");
+        context.addServletMapping("/timeout", "timeout");
+        context.addServletMapping("/error", "customErrorServlet");
         ErrorPage errorPage = new ErrorPage();
         errorPage.setLocation("/error");
         context.addErrorPage(errorPage);
@@ -2491,7 +2491,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         } else {
             Tomcat.addServlet(context, "space", new ForwardDispatchUrlWithSpacesServlet());
         }
-        context.addServletMappingDecoded("/space/*", "space");
+        context.addServletMapping("/space/*", "space");
         tomcat.start();
 
         ByteChunk responseBody = new ByteChunk();
@@ -2587,7 +2587,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         EncodedDispatchServlet encodedDispatchServlet = new EncodedDispatchServlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "encodedDispatchServlet", encodedDispatchServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/*", "encodedDispatchServlet");
+        ctx.addServletMapping("/*", "encodedDispatchServlet");
 
         tomcat.start();
 
@@ -2657,11 +2657,11 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
             AsyncIoEndServlet asyncIoEndServlet = new AsyncIoEndServlet(useThread, useComplete);
             Wrapper wrapper = Tomcat.addServlet(ctx, "asyncIoEndServlet", asyncIoEndServlet);
             wrapper.setAsyncSupported(true);
-            ctx.addServletMappingDecoded("/asyncIoEndServlet", "asyncIoEndServlet");
+            ctx.addServletMapping("/asyncIoEndServlet", "asyncIoEndServlet");
 
             SimpleServlet simpleServlet = new SimpleServlet();
             Tomcat.addServlet(ctx, "simpleServlet", simpleServlet);
-            ctx.addServletMappingDecoded("/simpleServlet", "simpleServlet");
+            ctx.addServletMapping("/simpleServlet", "simpleServlet");
 
             tomcat.start();
 
@@ -2811,7 +2811,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         Bug63816Servlet bug63816Servlet = new Bug63816Servlet(doGetLatch, clientCloseLatch, threadCompleteLatch, ise);
         Wrapper wrapper = Tomcat.addServlet(ctx, "bug63816Servlet", bug63816Servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/*", "bug63816Servlet");
+        ctx.addServletMapping("/*", "bug63816Servlet");
 
         tomcat.start();
 
@@ -2979,7 +2979,7 @@ public class TestAsyncContextImpl extends TomcatBaseTest {
         PostServlet postServlet = new PostServlet(partialReadLatch, clientCloseLatch, threadCompleteLatch, testFailed);
         Wrapper wrapper = Tomcat.addServlet(ctx, "postServlet", postServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/*", "postServlet");
+        ctx.addServletMapping("/*", "postServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestAsyncContextImplDispatch.java b/test/org/apache/catalina/core/TestAsyncContextImplDispatch.java
index 9e40bfdd32..83bbdd9112 100644
--- a/test/org/apache/catalina/core/TestAsyncContextImplDispatch.java
+++ b/test/org/apache/catalina/core/TestAsyncContextImplDispatch.java
@@ -86,11 +86,11 @@ public class TestAsyncContextImplDispatch extends TomcatBaseTest {
 
         Wrapper w1 = Tomcat.addServlet(ctx, "target", new TesterServlet());
         w1.setAsyncSupported(targetAsyncSupported);
-        ctx.addServletMappingDecoded("/target", "target");
+        ctx.addServletMapping("/target", "target");
 
         Wrapper w2 = Tomcat.addServlet(ctx, "dispatch", new TesterDispatchServlet(dispatchAsyncStart));
         w2.setAsyncSupported(dispatchAsyncSupported);
-        ctx.addServletMappingDecoded("/dispatch", "dispatch");
+        ctx.addServletMapping("/dispatch", "dispatch");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestAsyncContextImplListenerOnComplete.java b/test/org/apache/catalina/core/TestAsyncContextImplListenerOnComplete.java
index aca065fff5..e58013094b 100644
--- a/test/org/apache/catalina/core/TestAsyncContextImplListenerOnComplete.java
+++ b/test/org/apache/catalina/core/TestAsyncContextImplListenerOnComplete.java
@@ -79,7 +79,7 @@ public class TestAsyncContextImplListenerOnComplete extends TomcatBaseTest {
         servletWrapper.setAsyncSupported(true);
         servletWrapper.setLoadOnStartup(1);
 
-        ctx.addServletMappingDecoded("/", "repro-servlet");
+        ctx.addServletMapping("/", "repro-servlet");
 
         tomcat.start();
         Thread.sleep(2000);
diff --git a/test/org/apache/catalina/core/TestAsyncContextIoError.java b/test/org/apache/catalina/core/TestAsyncContextIoError.java
index 52694b6b1d..787937563d 100644
--- a/test/org/apache/catalina/core/TestAsyncContextIoError.java
+++ b/test/org/apache/catalina/core/TestAsyncContextIoError.java
@@ -56,11 +56,11 @@ public class TestAsyncContextIoError extends TomcatBaseTest {
         AsyncServlet asyncServlet = new AsyncServlet();
         Wrapper asyncWrapper = Tomcat.addServlet(ctx, "async", asyncServlet);
         asyncWrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/async", "async");
+        ctx.addServletMapping("/async", "async");
 
         ErrorServlet errorServlet = new ErrorServlet();
         Tomcat.addServlet(ctx, "error", errorServlet);
-        ctx.addServletMappingDecoded("/error", "error");
+        ctx.addServletMapping("/error", "error");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestAsyncContextStateChanges.java b/test/org/apache/catalina/core/TestAsyncContextStateChanges.java
index 98b0d4899a..57160d51e0 100644
--- a/test/org/apache/catalina/core/TestAsyncContextStateChanges.java
+++ b/test/org/apache/catalina/core/TestAsyncContextStateChanges.java
@@ -105,7 +105,7 @@ public class TestAsyncContextStateChanges extends TomcatBaseTest {
         AsyncServlet bug63816Servlet = new AsyncServlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "bug63816Servlet", bug63816Servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/*", "bug63816Servlet");
+        ctx.addServletMapping("/*", "bug63816Servlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestPropertiesRoleMappingListener.java b/test/org/apache/catalina/core/TestPropertiesRoleMappingListener.java
index ff92b1244a..759ec9ddd2 100644
--- a/test/org/apache/catalina/core/TestPropertiesRoleMappingListener.java
+++ b/test/org/apache/catalina/core/TestPropertiesRoleMappingListener.java
@@ -119,7 +119,7 @@ public class TestPropertiesRoleMappingListener extends TomcatBaseTest {
         ctx.addLifecycleListener(listener);
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         LoginConfig loginConfig = new LoginConfig();
         loginConfig.setAuthMethod(HttpServletRequest.BASIC_AUTH);
diff --git a/test/org/apache/catalina/core/TestStandardContext.java b/test/org/apache/catalina/core/TestStandardContext.java
index 95c7924dac..ed580a3bed 100644
--- a/test/org/apache/catalina/core/TestStandardContext.java
+++ b/test/org/apache/catalina/core/TestStandardContext.java
@@ -145,13 +145,13 @@ public class TestStandardContext extends TomcatBaseTest {
         context.addFilterDef(filterDef);
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName("Bug46243");
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         context.addFilterMap(filterMap);
 
         // Add a test servlet so there is something to generate a response if
         // it works (although it shouldn't)
         Tomcat.addServlet(context, "Bug46243", new HelloWorldServlet());
-        context.addServletMappingDecoded("/", "Bug46243");
+        context.addServletMapping("/", "Bug46243");
     }
 
     private static final class Bug46243Client extends SimpleHttpClient {
@@ -715,8 +715,8 @@ public class TestStandardContext extends TomcatBaseTest {
             // to set our own MultipartConfigElement.
             w.setMultipartConfigElement(new MultipartConfigElement(""));
 
-            context.addServletMappingDecoded("/regular", "regular");
-            context.addServletMappingDecoded("/multipart", "multipart");
+            context.addServletMapping("/regular", "regular");
+            context.addServletMapping("/multipart", "multipart");
             tomcat.start();
 
             setPort(tomcat.getConnector().getLocalPort());
diff --git a/test/org/apache/catalina/core/TestStandardContextAliases.java b/test/org/apache/catalina/core/TestStandardContextAliases.java
index 6e2f0ac01c..a9d0a34180 100644
--- a/test/org/apache/catalina/core/TestStandardContextAliases.java
+++ b/test/org/apache/catalina/core/TestStandardContextAliases.java
@@ -53,7 +53,7 @@ public class TestStandardContextAliases extends TomcatBaseTest {
 
 
         Tomcat.addServlet(ctx, "test", new TestServlet());
-        ctx.addServletMappingDecoded("/", "test");
+        ctx.addServletMapping("/", "test");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestStandardContextResources.java b/test/org/apache/catalina/core/TestStandardContextResources.java
index 8892d8e888..2d838e9835 100644
--- a/test/org/apache/catalina/core/TestStandardContextResources.java
+++ b/test/org/apache/catalina/core/TestStandardContextResources.java
@@ -119,7 +119,7 @@ public class TestStandardContextResources extends TomcatBaseTest {
                 (StandardContext) tomcat.addWebapp(null, "/test", appDir.getAbsolutePath(), absoluteOrderConfig);
 
         Tomcat.addServlet(ctx, "getresource", new GetResourceServlet());
-        ctx.addServletMappingDecoded("/getresource", "getresource");
+        ctx.addServletMapping("/getresource", "getresource");
 
         tomcat.start();
         assertPageContains("/test/getresource?path=/resourceF.jsp", "<p>resourceF.jsp in resources2.jar</p>");
@@ -137,7 +137,7 @@ public class TestStandardContextResources extends TomcatBaseTest {
 
         ctx = (StandardContext) tomcat.addWebapp(null, "/test", appDir.getAbsolutePath(), absoluteOrderConfig);
         Tomcat.addServlet(ctx, "getresource", new GetResourceServlet());
-        ctx.addServletMappingDecoded("/getresource", "getresource");
+        ctx.addServletMapping("/getresource", "getresource");
 
         tomcat.getHost().start();
 
@@ -189,7 +189,7 @@ public class TestStandardContextResources extends TomcatBaseTest {
         skipTldsForResourceJars(ctx);
 
         Tomcat.addServlet(ctx, "getresource", new GetResourceServlet());
-        ctx.addServletMappingDecoded("/getresource", "getresource");
+        ctx.addServletMapping("/getresource", "getresource");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestStandardContextValve.java b/test/org/apache/catalina/core/TestStandardContextValve.java
index 367ff8adc9..4855f24789 100644
--- a/test/org/apache/catalina/core/TestStandardContextValve.java
+++ b/test/org/apache/catalina/core/TestStandardContextValve.java
@@ -54,7 +54,7 @@ public class TestStandardContextValve extends TomcatBaseTest {
 
         // Add the error page
         Tomcat.addServlet(ctx, "errorPage", new Bug51653ErrorPage(trace));
-        ctx.addServletMappingDecoded("/error", "errorPage");
+        ctx.addServletMapping("/error", "errorPage");
         // And the handling for 404 responses
         ErrorPage errorPage = new ErrorPage();
         errorPage.setErrorCode(Response.SC_NOT_FOUND);
@@ -99,11 +99,11 @@ public class TestStandardContextValve extends TomcatBaseTest {
 
         // Add the page that generates the error
         Tomcat.addServlet(ctx, "test", new Bug51653ErrorTrigger());
-        ctx.addServletMappingDecoded("/test", "test");
+        ctx.addServletMapping("/test", "test");
 
         // Add the error page
         Tomcat.addServlet(ctx, "errorPage", new Bug51653ErrorPage(trace));
-        ctx.addServletMappingDecoded("/error", "errorPage");
+        ctx.addServletMapping("/error", "errorPage");
         // And the handling for 404 responses
         ErrorPage errorPage = new ErrorPage();
         errorPage.setErrorCode(Response.SC_NOT_FOUND);
@@ -230,7 +230,7 @@ public class TestStandardContextValve extends TomcatBaseTest {
         final Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "echo", new EchoBodyServlet());
-        ctx.addServletMappingDecoded("/echo", "echo");
+        ctx.addServletMapping("/echo", "echo");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/core/TestStandardHostValve.java b/test/org/apache/catalina/core/TestStandardHostValve.java
index 37b56c3295..48b4c847d7 100644
--- a/test/org/apache/catalina/core/TestStandardHostValve.java
+++ b/test/org/apache/catalina/core/TestStandardHostValve.java
@@ -84,11 +84,11 @@ public class TestStandardHostValve extends TomcatBaseTest {
 
         // Add the error page
         Tomcat.addServlet(ctx, "error", new ErrorServlet());
-        ctx.addServletMappingDecoded("/error", "error");
+        ctx.addServletMapping("/error", "error");
 
         // Add the error handling page
         Tomcat.addServlet(ctx, "report", new ReportServlet());
-        ctx.addServletMappingDecoded("/report/*", "report");
+        ctx.addServletMapping("/report/*", "report");
 
         // Add the handling for 400 responses
         ErrorPage errorPage400 = new ErrorPage();
@@ -158,7 +158,7 @@ public class TestStandardHostValve extends TomcatBaseTest {
 
         // Add the error page
         Tomcat.addServlet(ctx, "error", new ErrorServlet());
-        ctx.addServletMappingDecoded("/error", "error");
+        ctx.addServletMapping("/error", "error");
 
         final List<String> result = new ArrayList<>();
 
@@ -200,11 +200,11 @@ public class TestStandardHostValve extends TomcatBaseTest {
 
         // Add the error page
         Tomcat.addServlet(ctx, "error", new ExceptionServlet());
-        ctx.addServletMappingDecoded("/error", "error");
+        ctx.addServletMapping("/error", "error");
 
         // Add the error handling page
         Tomcat.addServlet(ctx, "report", new ReportServlet());
-        ctx.addServletMappingDecoded("/report/*", "report");
+        ctx.addServletMapping("/report/*", "report");
 
         // Add the handling for 500 responses
         ErrorPage errorPage500 = new ErrorPage();
diff --git a/test/org/apache/catalina/core/TestStandardWrapper.java b/test/org/apache/catalina/core/TestStandardWrapper.java
index 79a201f020..5e70a9d27e 100644
--- a/test/org/apache/catalina/core/TestStandardWrapper.java
+++ b/test/org/apache/catalina/core/TestStandardWrapper.java
@@ -250,7 +250,7 @@ public class TestStandardWrapper extends TomcatBaseTest {
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", RoleAllowServlet.class.getName());
         wrapper.addSecurityReference("testSecurityRoleRef", "very-complex-role-name");
         wrapper.addSecurityReference("testSecurityRoleRef2", "testRole");
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         ctx.setLoginConfig(new LoginConfig("BASIC", null, null, null));
         ctx.getPipeline().addValve(new BasicAuthenticator());
@@ -347,7 +347,7 @@ public class TestStandardWrapper extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servletClassName);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         if (useRole) {
             TesterMapRealm realm = new TesterMapRealm();
diff --git a/test/org/apache/catalina/core/TestSwallowAbortedUploads.java b/test/org/apache/catalina/core/TestSwallowAbortedUploads.java
index aea3986e0a..4249ad37cc 100644
--- a/test/org/apache/catalina/core/TestSwallowAbortedUploads.java
+++ b/test/org/apache/catalina/core/TestSwallowAbortedUploads.java
@@ -234,7 +234,7 @@ public class TestSwallowAbortedUploads extends TomcatBaseTest {
             } else {
                 w.setMultipartConfigElement(new MultipartConfigElement(""));
             }
-            context.addServletMappingDecoded(URI, servletName);
+            context.addServletMapping(URI, servletName);
             context.setSwallowAbortedUploads(swallow);
 
             Connector c = tomcat.getConnector();
@@ -345,7 +345,7 @@ public class TestSwallowAbortedUploads extends TomcatBaseTest {
             context = tomcat.addContext("", TEMP_DIR);
             AbortedPOSTServlet servlet = new AbortedPOSTServlet(status);
             Tomcat.addServlet(context, servletName, servlet);
-            context.addServletMappingDecoded(URI, servletName);
+            context.addServletMapping(URI, servletName);
             context.setSwallowAbortedUploads(swallow);
 
             tomcat.start();
diff --git a/test/org/apache/catalina/filters/TestAddCharSetFilter.java b/test/org/apache/catalina/filters/TestAddCharSetFilter.java
index e8a252130a..361197b774 100644
--- a/test/org/apache/catalina/filters/TestAddCharSetFilter.java
+++ b/test/org/apache/catalina/filters/TestAddCharSetFilter.java
@@ -98,7 +98,7 @@ public class TestAddCharSetFilter extends TomcatBaseTest {
         // Add the Servlet
         CharsetServlet servlet = new CharsetServlet(mode, useSetContentType);
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         // Add the Filter
         FilterDef filterDef = new FilterDef();
diff --git a/test/org/apache/catalina/filters/TestExpiresFilter.java b/test/org/apache/catalina/filters/TestExpiresFilter.java
index b659099b76..3a95ca4e5b 100644
--- a/test/org/apache/catalina/filters/TestExpiresFilter.java
+++ b/test/org/apache/catalina/filters/TestExpiresFilter.java
@@ -75,7 +75,7 @@ public class TestExpiresFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(ExpiresFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
 
         tomcat.start();
         try {
@@ -388,11 +388,11 @@ public class TestExpiresFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(ExpiresFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         root.addFilterMap(filterMap);
 
         Tomcat.addServlet(root, servlet.getClass().getName(), servlet);
-        root.addServletMappingDecoded("/test", servlet.getClass().getName());
+        root.addServletMapping("/test", servlet.getClass().getName());
 
         tomcat.start();
 
@@ -507,7 +507,7 @@ public class TestExpiresFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(ExpiresFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         ctxt.addFilterMap(filterMap);
 
         tomcat.start();
diff --git a/test/org/apache/catalina/filters/TestRateLimitFilter.java b/test/org/apache/catalina/filters/TestRateLimitFilter.java
index f12a8332c6..5cdf4e6394 100644
--- a/test/org/apache/catalina/filters/TestRateLimitFilter.java
+++ b/test/org/apache/catalina/filters/TestRateLimitFilter.java
@@ -136,7 +136,7 @@ public class TestRateLimitFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(RateLimitFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         root.addFilterMap(filterMap);
 
         return rateLimitFilter;
diff --git a/test/org/apache/catalina/filters/TestRateLimitFilterWithExactRateLimiter.java b/test/org/apache/catalina/filters/TestRateLimitFilterWithExactRateLimiter.java
index 65681195a5..de2e2a7aad 100644
--- a/test/org/apache/catalina/filters/TestRateLimitFilterWithExactRateLimiter.java
+++ b/test/org/apache/catalina/filters/TestRateLimitFilterWithExactRateLimiter.java
@@ -141,7 +141,7 @@ public class TestRateLimitFilterWithExactRateLimiter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(RateLimitFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         root.addFilterMap(filterMap);
 
         return rateLimitFilter;
diff --git a/test/org/apache/catalina/filters/TestRemoteCIDRFilter.java b/test/org/apache/catalina/filters/TestRemoteCIDRFilter.java
index c89e9f6e7e..39b60f049c 100644
--- a/test/org/apache/catalina/filters/TestRemoteCIDRFilter.java
+++ b/test/org/apache/catalina/filters/TestRemoteCIDRFilter.java
@@ -228,7 +228,7 @@ public class TestRemoteCIDRFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(testFilterClass.getName());
-        filterMap.addURLPatternDecoded(urlPattern);
+        filterMap.addURLPattern(urlPattern);
         root.addFilterMap(filterMap);
 
         FilterConfig filterConfig = TesterFilterConfigs.generateFilterConfig(filterDef);
diff --git a/test/org/apache/catalina/filters/TestRemoteIpFilter.java b/test/org/apache/catalina/filters/TestRemoteIpFilter.java
index 5243a3c623..9d0eef9ff0 100644
--- a/test/org/apache/catalina/filters/TestRemoteIpFilter.java
+++ b/test/org/apache/catalina/filters/TestRemoteIpFilter.java
@@ -670,7 +670,7 @@ public class TestRemoteIpFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(RemoteIpFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         root.addFilterMap(filterMap);
 
         getTomcatInstance().start();
@@ -755,13 +755,13 @@ public class TestRemoteIpFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(RemoteIpFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         root.addFilterMap(filterMap);
 
         MockHttpServlet mockServlet = new MockHttpServlet();
 
         Tomcat.addServlet(root, mockServlet.getClass().getName(), mockServlet);
-        root.addServletMappingDecoded("/test", mockServlet.getClass().getName());
+        root.addServletMapping("/test", mockServlet.getClass().getName());
 
         getTomcatInstance().start();
 
@@ -805,13 +805,13 @@ public class TestRemoteIpFilter extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(RemoteIpFilter.class.getName());
-        filterMap.addURLPatternDecoded("*");
+        filterMap.addURLPattern("*");
         root.addFilterMap(filterMap);
 
         Bug66471Servlet bug66471Servlet = new Bug66471Servlet();
 
         Tomcat.addServlet(root, bug66471Servlet.getClass().getName(), bug66471Servlet);
-        root.addServletMappingDecoded("/test", bug66471Servlet.getClass().getName());
+        root.addServletMapping("/test", bug66471Servlet.getClass().getName());
 
         getTomcatInstance().start();
 
diff --git a/test/org/apache/catalina/filters/TestRestCsrfPreventionFilter2.java b/test/org/apache/catalina/filters/TestRestCsrfPreventionFilter2.java
index 3ce7b845ee..129bf3fa0e 100644
--- a/test/org/apache/catalina/filters/TestRestCsrfPreventionFilter2.java
+++ b/test/org/apache/catalina/filters/TestRestCsrfPreventionFilter2.java
@@ -270,7 +270,7 @@ public class TestRestCsrfPreventionFilter2 extends TomcatBaseTest {
         context.setSessionTimeout(SHORT_SESSION_TIMEOUT_MINS);
 
         Tomcat.addServlet(context, SERVLET_NAME, new TesterServlet());
-        context.addServletMappingDecoded(URI_PROTECTED, SERVLET_NAME);
+        context.addServletMapping(URI_PROTECTED, SERVLET_NAME);
 
         FilterDef filterDef = new FilterDef();
         filterDef.setFilterName(FILTER_NAME);
@@ -280,11 +280,11 @@ public class TestRestCsrfPreventionFilter2 extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName(FILTER_NAME);
-        filterMap.addURLPatternDecoded(URI_CSRF_PROTECTED);
+        filterMap.addURLPattern(URI_CSRF_PROTECTED);
         context.addFilterMap(filterMap);
 
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded(URI_PROTECTED);
+        collection.addPattern(URI_PROTECTED);
 
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
diff --git a/test/org/apache/catalina/ha/context/TestReplicatedContext.java b/test/org/apache/catalina/ha/context/TestReplicatedContext.java
index 3840a19249..52d72ed896 100644
--- a/test/org/apache/catalina/ha/context/TestReplicatedContext.java
+++ b/test/org/apache/catalina/ha/context/TestReplicatedContext.java
@@ -49,7 +49,7 @@ public class TestReplicatedContext extends TomcatBaseTest {
         Context context = tomcat.addWebapp(host, "", root.getAbsolutePath());
 
         Tomcat.addServlet(context, "test", new AccessContextServlet());
-        context.addServletMappingDecoded("/access", "test");
+        context.addServletMapping("/access", "test");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/loader/TestWebappClassLoaderExecutorMemoryLeak.java b/test/org/apache/catalina/loader/TestWebappClassLoaderExecutorMemoryLeak.java
index 558513fd93..821e0264da 100644
--- a/test/org/apache/catalina/loader/TestWebappClassLoaderExecutorMemoryLeak.java
+++ b/test/org/apache/catalina/loader/TestWebappClassLoaderExecutorMemoryLeak.java
@@ -49,7 +49,7 @@ public class TestWebappClassLoaderExecutorMemoryLeak extends TomcatBaseTest {
 
         ExecutorServlet executorServlet = new ExecutorServlet();
         Tomcat.addServlet(ctx, "taskServlet", executorServlet);
-        ctx.addServletMappingDecoded("/", "taskServlet");
+        ctx.addServletMapping("/", "taskServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/loader/TestWebappClassLoaderMemoryLeak.java b/test/org/apache/catalina/loader/TestWebappClassLoaderMemoryLeak.java
index 70b069c340..e869335e98 100644
--- a/test/org/apache/catalina/loader/TestWebappClassLoaderMemoryLeak.java
+++ b/test/org/apache/catalina/loader/TestWebappClassLoaderMemoryLeak.java
@@ -47,7 +47,7 @@ public class TestWebappClassLoaderMemoryLeak extends TomcatBaseTest {
         }
 
         Tomcat.addServlet(ctx, "taskServlet", new TaskServlet());
-        ctx.addServletMappingDecoded("/", "taskServlet");
+        ctx.addServletMapping("/", "taskServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/loader/TesterWebappClassLoaderThreadLocalMemoryLeak.java b/test/org/apache/catalina/loader/TesterWebappClassLoaderThreadLocalMemoryLeak.java
index b65e87fa26..0d6645e8a8 100644
--- a/test/org/apache/catalina/loader/TesterWebappClassLoaderThreadLocalMemoryLeak.java
+++ b/test/org/apache/catalina/loader/TesterWebappClassLoaderThreadLocalMemoryLeak.java
@@ -61,7 +61,7 @@ public class TesterWebappClassLoaderThreadLocalMemoryLeak extends TomcatBaseTest
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "leakServlet1", "org.apache.tomcat.unittest.TesterLeakingServlet1");
-        ctx.addServletMappingDecoded("/leak1", "leakServlet1");
+        ctx.addServletMapping("/leak1", "leakServlet1");
 
         tomcat.start();
 
@@ -110,7 +110,7 @@ public class TesterWebappClassLoaderThreadLocalMemoryLeak extends TomcatBaseTest
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "leakServlet2", "org.apache.tomcat.unittest.TesterLeakingServlet2");
-        ctx.addServletMappingDecoded("/leak2", "leakServlet2");
+        ctx.addServletMapping("/leak2", "leakServlet2");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/manager/TestHostManagerWebapp.java b/test/org/apache/catalina/manager/TestHostManagerWebapp.java
index c174750f3a..272c416f6e 100644
--- a/test/org/apache/catalina/manager/TestHostManagerWebapp.java
+++ b/test/org/apache/catalina/manager/TestHostManagerWebapp.java
@@ -68,7 +68,7 @@ public class TestHostManagerWebapp extends TomcatBaseTest {
 
         Context context = getProgrammaticRootContext();
         Tomcat.addServlet(context, "hello", new HelloWorldServlet());
-        context.addServletMappingDecoded("/", "hello");
+        context.addServletMapping("/", "hello");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/manager/TestManagerWebapp.java b/test/org/apache/catalina/manager/TestManagerWebapp.java
index 666726ed58..b2ff8cd664 100644
--- a/test/org/apache/catalina/manager/TestManagerWebapp.java
+++ b/test/org/apache/catalina/manager/TestManagerWebapp.java
@@ -633,7 +633,7 @@ public class TestManagerWebapp extends TomcatBaseTest {
 
         Context ctx = tomcat.addContext("/testapp", null);
         Tomcat.addServlet(ctx, "default", new org.apache.catalina.servlets.DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/manager/TestStatusTransformer.java b/test/org/apache/catalina/manager/TestStatusTransformer.java
index 5cb32126a4..17f43fc8d6 100644
--- a/test/org/apache/catalina/manager/TestStatusTransformer.java
+++ b/test/org/apache/catalina/manager/TestStatusTransformer.java
@@ -67,13 +67,13 @@ public class TestStatusTransformer extends TomcatBaseTest {
         ctxt.setPrivileged(true);
         Wrapper defaultServlet = Tomcat.addServlet(ctxt, "default", "org.apache.catalina.servlets.DefaultServlet");
         defaultServlet.addInitParameter("fileEncoding", "ISO-8859-1");
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
         Tomcat.addServlet(ctxt, "status", "org.apache.catalina.manager.StatusManagerServlet");
-        ctxt.addServletMappingDecoded("/status/*", "status");
+        ctxt.addServletMapping("/status/*", "status");
         ctxt.addMimeMapping("html", "text/html");
         Context ctxt2 = tomcat.addContext("/test", null);
         Tomcat.addServlet(ctxt2, "status", "org.apache.catalina.manager.StatusManagerServlet");
-        ctxt.addServletMappingDecoded("/somepath/*", "status");
+        ctxt.addServletMapping("/somepath/*", "status");
         tomcat.start();
 
         SimpleHttpClient client = new SimpleHttpClient() {
diff --git a/test/org/apache/catalina/mapper/TestMapperWebapps.java b/test/org/apache/catalina/mapper/TestMapperWebapps.java
index 52722e605d..0b041d666a 100644
--- a/test/org/apache/catalina/mapper/TestMapperWebapps.java
+++ b/test/org/apache/catalina/mapper/TestMapperWebapps.java
@@ -125,7 +125,7 @@ public class TestMapperWebapps extends TomcatBaseTest {
         ctx.setMapperContextRootRedirectEnabled(rootRedirect);
 
         Tomcat.addServlet(ctx, "ReportMapping", new ReportMappingServlet());
-        ctx.addServletMappingDecoded("", "ReportMapping");
+        ctx.addServletMapping("", "ReportMapping");
 
         tomcat.start();
 
@@ -286,8 +286,8 @@ public class TestMapperWebapps extends TomcatBaseTest {
         // Add a security constraint
         SecurityConstraint constraint = new SecurityConstraint();
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded("/welcome-files/*");
-        collection.addPatternDecoded("/welcome-files");
+        collection.addPattern("/welcome-files/*");
+        collection.addPattern("/welcome-files");
         constraint.addCollection(collection);
         constraint.addAuthRole("foo");
         root.addConstraint(constraint);
diff --git a/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java b/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
index e9c86871b2..886e948c98 100644
--- a/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
+++ b/test/org/apache/catalina/nonblocking/TestNonBlockingAPI.java
@@ -137,7 +137,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         NBReadServlet servlet = new NBReadServlet(ignoreIsReady, async, null);
         String servletName = NBReadServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.start();
 
@@ -629,7 +629,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         NBReadServlet servlet = new NBReadServlet(false, true, expectedTrailerFieldValue);
         String servletName = NBReadServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.getConnector().setProperty("allowedTrailerHeaders", TRAILER_HEADER_NAME);
 
@@ -692,7 +692,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         NBWriteServlet servlet = new NBWriteServlet(asyncContextIsComplete);
         String servletName = NBWriteServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
         // Note: Low values of socket.txBufSize can trigger very poor
         // performance. Set it just low enough to ensure that the
         // non-blocking write servlet will see isReady() == false
@@ -872,7 +872,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         NBWriteServlet servlet = new NBWriteServlet(asyncContextIsComplete, true, listenerCompletesOnError);
         String servletName = NBWriteServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
         // Note: Low values of socket.txBufSize can trigger very poor
         // performance. Set it just low enough to ensure that the
         // non-blocking write servlet will see isReady() == false
@@ -958,7 +958,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         NBReadWriteServlet servlet = new NBReadWriteServlet();
         String servletName = NBReadWriteServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.start();
 
@@ -1469,7 +1469,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         DelayedNBWriteServlet servlet = new DelayedNBWriteServlet(latch1);
         String servletName = DelayedNBWriteServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.start();
 
@@ -1501,7 +1501,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         DelayedNBReadWriteServlet servlet = new DelayedNBReadWriteServlet(latch1);
         String servletName = DelayedNBReadWriteServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.start();
 
@@ -1758,7 +1758,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         NBReadWithDispatchServlet servlet = new NBReadWithDispatchServlet();
         String servletName = NBReadWithDispatchServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.start();
 
@@ -1882,7 +1882,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
         PostServlet postServlet = new PostServlet(partialReadLatch, completeLatch, testFailed);
         Wrapper wrapper = Tomcat.addServlet(ctx, "postServlet", postServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/*", "postServlet");
+        ctx.addServletMapping("/*", "postServlet");
 
         tomcat.start();
 
@@ -2055,7 +2055,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
                 new NBWriteServlet02(responseCommitLatch, clientCloseLatch, asyncCompleteLatch, swallowIoException);
         Wrapper wrapper = Tomcat.addServlet(ctx, "writeServlet", writeServlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/*", "writeServlet");
+        ctx.addServletMapping("/*", "writeServlet");
 
         tomcat.start();
 
@@ -2227,7 +2227,7 @@ public class TestNonBlockingAPI extends TomcatBaseTest {
                 beforeCloseLatch, afterCloseLatch, written);
         String servletName = NBWriteWithCloseServlet.class.getName();
         Tomcat.addServlet(ctx, servletName, servlet);
-        ctx.addServletMappingDecoded("/", servletName);
+        ctx.addServletMapping("/", servletName);
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/realm/TestRealmBase.java b/test/org/apache/catalina/realm/TestRealmBase.java
index 8c564e44b7..3f920976dd 100644
--- a/test/org/apache/catalina/realm/TestRealmBase.java
+++ b/test/org/apache/catalina/realm/TestRealmBase.java
@@ -661,7 +661,7 @@ public class TestRealmBase {
         deleteConstraint.addAuthRole(ROLE1);
         SecurityCollection deleteCollection = new SecurityCollection();
         deleteCollection.addMethod(Method.DELETE);
-        deleteCollection.addPatternDecoded("/*");
+        deleteCollection.addPattern("/*");
         deleteConstraint.addCollection(deleteCollection);
 
         TesterMapRealm mapRealm = new TesterMapRealm();
@@ -800,12 +800,12 @@ public class TestRealmBase {
         // Add a collection for GET
         SecurityCollection getCollection = new SecurityCollection();
         getCollection.addMethod(Method.GET);
-        getCollection.addPatternDecoded("*.html");
+        getCollection.addPattern("*.html");
         constraint.addCollection(getCollection);
         // Add a collection for POST
         SecurityCollection postCollection = new SecurityCollection();
         postCollection.addMethod(Method.POST);
-        postCollection.addPatternDecoded("*.html");
+        postCollection.addPattern("*.html");
         constraint.addCollection(postCollection);
 
         TesterMapRealm mapRealm = new TesterMapRealm();
@@ -880,13 +880,13 @@ public class TestRealmBase {
         SecurityConstraint allowConstraint = new SecurityConstraint();
         SecurityCollection allowCollection = new SecurityCollection();
         allowCollection.addMethod(Method.GET);
-        allowCollection.addPatternDecoded("/");
+        allowCollection.addPattern("/");
         allowConstraint.addCollection(allowCollection);
         // Create a constraint that disallows everything but GET
         SecurityConstraint blockConstraint = new SecurityConstraint();
         SecurityCollection blockCollection = new SecurityCollection();
         blockCollection.addOmittedMethod(Method.GET);
-        blockCollection.addPatternDecoded("/");
+        blockCollection.addPattern("/");
         blockConstraint.addCollection(blockCollection);
         blockConstraint.addAuthRole(ROLE1);
 
diff --git a/test/org/apache/catalina/servlets/DefaultServletEncodingBaseTest.java b/test/org/apache/catalina/servlets/DefaultServletEncodingBaseTest.java
index 740ff5c9ca..6d500aef10 100644
--- a/test/org/apache/catalina/servlets/DefaultServletEncodingBaseTest.java
+++ b/test/org/apache/catalina/servlets/DefaultServletEncodingBaseTest.java
@@ -190,12 +190,12 @@ public abstract class DefaultServletEncodingBaseTest extends TomcatBaseTest {
         defaultServlet.addInitParameter("fileEncoding", fileEncoding);
         defaultServlet.addInitParameter("useBomIfPresent", getUseBom().configurationValue);
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         if (useInclude) {
             Tomcat.addServlet(ctxt, "include", new EncodingServlet(
                     outputEncoding, callSetCharacterEncoding, targetFile, useWriter));
-            ctxt.addServletMappingDecoded("/include", "include");
+            ctxt.addServletMapping("/include", "include");
         }
 
         tomcat.start();
diff --git a/test/org/apache/catalina/servlets/ServletOptionsBaseTest.java b/test/org/apache/catalina/servlets/ServletOptionsBaseTest.java
index d3d80d15dc..95525d92ed 100644
--- a/test/org/apache/catalina/servlets/ServletOptionsBaseTest.java
+++ b/test/org/apache/catalina/servlets/ServletOptionsBaseTest.java
@@ -86,7 +86,7 @@ public abstract class ServletOptionsBaseTest extends TomcatBaseTest {
         w.addInitParameter("readonly", Boolean.toString(readonly));
         w.addInitParameter("allowPostAsGet", "true");
 
-        ctx.addServletMappingDecoded("/*", "servlet");
+        ctx.addServletMapping("/*", "servlet");
 
         // Disable class path scanning - it slows the tests down by almost an order of magnitude
         ((StandardJarScanner) ctx.getJarScanner()).setScanClassPath(false);
diff --git a/test/org/apache/catalina/servlets/TestDefaultServlet.java b/test/org/apache/catalina/servlets/TestDefaultServlet.java
index 49f14a4f37..934ecd34ce 100644
--- a/test/org/apache/catalina/servlets/TestDefaultServlet.java
+++ b/test/org/apache/catalina/servlets/TestDefaultServlet.java
@@ -100,7 +100,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
         Wrapper defaultServlet = Tomcat.addServlet(ctxt, "default",
                 "org.apache.catalina.servlets.DefaultServlet");
         defaultServlet.addInitParameter("fileEncoding", "ISO-8859-1");
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         ctxt.addMimeMapping("html", "text/html");
 
@@ -146,7 +146,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
                 "org.apache.catalina.servlets.DefaultServlet");
         defaultServlet.addInitParameter("gzip", "true");
         defaultServlet.addInitParameter("fileEncoding", "ISO-8859-1");
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         ctxt.addMimeMapping("html", "text/html");
 
@@ -203,7 +203,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
         defaultServlet.addInitParameter("precompressed", "true");
         defaultServlet.addInitParameter("fileEncoding", "ISO-8859-1");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
         ctxt.addMimeMapping("html", "text/html");
 
         tomcat.start();
@@ -266,7 +266,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
                 DefaultServlet.class.getName());
         defaultServlet.addInitParameter("precompressed", "gzip=.gz,custom=.br");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
         ctxt.addMimeMapping("html", "text/html");
 
         tomcat.start();
@@ -329,7 +329,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
         defaultServlet.addInitParameter("precompressed", "br=.br,gzip=.gz");
         defaultServlet.addInitParameter("fileEncoding", "ISO-8859-1");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
         ctxt.addMimeMapping("html", "text/html");
 
         tomcat.start();
@@ -391,7 +391,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
                 DefaultServlet.class.getName());
         defaultServlet.addInitParameter("precompressed", "true");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
         ctxt.addMimeMapping("html", "text/html");
 
         tomcat.start();
@@ -454,9 +454,9 @@ public class TestDefaultServlet extends TomcatBaseTest {
 
         // Override the default servlet with our own mappings
         Tomcat.addServlet(ctx, "default2", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default2");
-        ctx.addServletMappingDecoded("/servlets/*", "default2");
-        ctx.addServletMappingDecoded("/static/*", "default2");
+        ctx.addServletMapping("/", "default2");
+        ctx.addServletMapping("/servlets/*", "default2");
+        ctx.addServletMapping("/static/*", "default2");
 
         tomcat.start();
 
@@ -524,7 +524,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
                 DefaultServlet.class.getName());
         defaultServlet.addInitParameter("fileEncoding", "ISO-8859-1");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
         ctxt.addMimeMapping("html", "text/html");
         ErrorPage ep = new ErrorPage();
         ep.setErrorCode(404);
@@ -709,7 +709,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
         defaultServlet.addInitParameter("listings", "true");
         defaultServlet.addInitParameter("localXsltFile", "_listing.xslt");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -742,7 +742,7 @@ public class TestDefaultServlet extends TomcatBaseTest {
         defaultServlet.addInitParameter("sortListings", "true");
         defaultServlet.addInitParameter("sortDirectoriesFirst", "true");
 
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/servlets/TestDefaultServletIfMatchRequests.java b/test/org/apache/catalina/servlets/TestDefaultServletIfMatchRequests.java
index bcfa359388..40815a3b7d 100644
--- a/test/org/apache/catalina/servlets/TestDefaultServletIfMatchRequests.java
+++ b/test/org/apache/catalina/servlets/TestDefaultServletIfMatchRequests.java
@@ -178,7 +178,7 @@ public class TestDefaultServletIfMatchRequests extends TomcatBaseTest {
         if (resourceHasStrongETag) {
             wrapper.addInitParameter("useStrongETags", "true");
         }
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/servlets/TestDefaultServletPut.java b/test/org/apache/catalina/servlets/TestDefaultServletPut.java
index cff687cc53..5788a34656 100644
--- a/test/org/apache/catalina/servlets/TestDefaultServletPut.java
+++ b/test/org/apache/catalina/servlets/TestDefaultServletPut.java
@@ -130,7 +130,7 @@ public class TestDefaultServletPut extends TomcatBaseTest {
         Wrapper w = Tomcat.addServlet(ctxt, "default", DefaultServlet.class.getName());
         w.addInitParameter("readonly", "false");
         w.addInitParameter("allowPartialPut", Boolean.toString(allowPartialPut));
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/servlets/TestDefaultServletRangeRequests.java b/test/org/apache/catalina/servlets/TestDefaultServletRangeRequests.java
index f560a2af20..dd77083de2 100644
--- a/test/org/apache/catalina/servlets/TestDefaultServletRangeRequests.java
+++ b/test/org/apache/catalina/servlets/TestDefaultServletRangeRequests.java
@@ -171,7 +171,7 @@ public class TestDefaultServletRangeRequests extends TomcatBaseTest {
         if (ifRangeHeader != null && ifRangeHeader.startsWith("\"")) {
             wrapper.addInitParameter("useStrongETags", "true");
         }
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section13.java b/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section13.java
index 8a49cb6049..9aeb7d689f 100644
--- a/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section13.java
+++ b/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section13.java
@@ -579,7 +579,7 @@ public class TestDefaultServletRfc9110Section13 extends TomcatBaseTest {
         w.addInitParameter("allowPartialPut", "true");
         w.addInitParameter("allowPostAsGet", "true");
         w.addInitParameter("useStrongETags", Boolean.toString(useStrongETags));
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section14.java b/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section14.java
index efd266f8a6..5ccce0e5c6 100644
--- a/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section14.java
+++ b/test/org/apache/catalina/servlets/TestDefaultServletRfc9110Section14.java
@@ -44,7 +44,7 @@ public class TestDefaultServletRfc9110Section14 extends TomcatBaseTest {
         Context ctxt = tomcat.addContext("", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "default", DefaultServlet.class.getName());
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -79,7 +79,7 @@ public class TestDefaultServletRfc9110Section14 extends TomcatBaseTest {
         Context ctxt = tomcat.addContext("", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "default", DefaultServlet.class.getName());
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/servlets/TestWebdavServlet.java b/test/org/apache/catalina/servlets/TestWebdavServlet.java
index d5eaa5c2f5..832722eb97 100644
--- a/test/org/apache/catalina/servlets/TestWebdavServlet.java
+++ b/test/org/apache/catalina/servlets/TestWebdavServlet.java
@@ -97,10 +97,10 @@ public class TestWebdavServlet extends TomcatBaseTest {
 
         String contextPath="";
         if (useSubpathWebdav) {
-            ctx.addServletMappingDecoded("/webdav/*", "webdav");
+            ctx.addServletMapping("/webdav/*", "webdav");
             contextPath = "/webdav";
         } else {
-            ctx.addServletMappingDecoded("/*", "webdav");
+            ctx.addServletMapping("/*", "webdav");
         }
 
         tomcat.start();
@@ -146,7 +146,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         Context ctx = tomcat.addWebapp(null, "/examples", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctx, "webdav", new WebdavServlet());
-        ctx.addServletMappingDecoded("/webdav/*", "webdav");
+        ctx.addServletMapping("/webdav/*", "webdav");
         ctx.addApplicationListener(WsContextListener.class.getName());
 
         tomcat.start();
@@ -216,7 +216,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         Wrapper defaultServlet = Tomcat.addServlet(ctxt, "webdav", new WebdavServlet());
         defaultServlet.addInitParameter("listings", "true");
 
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         ctxt.addMimeMapping("html", "text/html");
 
         tomcat.start();
@@ -305,7 +305,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("listings", "true");
         webdavServlet.addInitParameter("secret", "foo");
         webdavServlet.addInitParameter("readonly", "false");
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         ctxt.addMimeMapping("txt", "text/plain");
         tomcat.start();
 
@@ -451,7 +451,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("secret", "foo");
         webdavServlet.addInitParameter("readonly", "false");
         webdavServlet.addInitParameter("useStrongETags", "true");
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         tomcat.start();
 
         ctxt.getResources().setCacheMaxSize(10);
@@ -937,7 +937,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("listings", "true");
         webdavServlet.addInitParameter("readonly", "false");
         webdavServlet.addInitParameter("serveSubpathOnly", "true");
-        ctxt.addServletMappingDecoded("/aaa/*", "webdav");
+        ctxt.addServletMapping("/aaa/*", "webdav");
         tomcat.start();
 
         ctxt.getResources().setCacheMaxSize(10);
@@ -1032,7 +1032,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("listings", "true");
         webdavServlet.addInitParameter("secret", "foo");
         webdavServlet.addInitParameter("readonly", "false");
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         tomcat.start();
 
         Client client = new Client();
@@ -1429,7 +1429,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("listings", "true");
         webdavServlet.addInitParameter("secret", "foo");
         webdavServlet.addInitParameter("readonly", "false");
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         tomcat.start();
 
         Client client = new Client();
@@ -1554,7 +1554,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("propertyStore", "org.apache.catalina.servlets.TestWebdavServlet$CustomPropertyStore");
         webdavServlet.addInitParameter("store.propertyName", "mytestproperty");
         webdavServlet.addInitParameter("store.propertyValue", "testvalue");
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         ctxt.addMimeMapping("txt", "text/plain");
         tomcat.start();
 
@@ -1609,7 +1609,7 @@ public class TestWebdavServlet extends TomcatBaseTest {
         webdavServlet.addInitParameter("useStrongETags", "true");
         webdavServlet.addInitParameter("maxRequestBodySize", "10");
 
-        ctxt.addServletMappingDecoded("/*", "webdav");
+        ctxt.addServletMapping("/*", "webdav");
         tomcat.start();
 
         // With content length
diff --git a/test/org/apache/catalina/session/TestPersistentManagerDataSourceStore.java b/test/org/apache/catalina/session/TestPersistentManagerDataSourceStore.java
index 0b95ba442e..98168d1853 100644
--- a/test/org/apache/catalina/session/TestPersistentManagerDataSourceStore.java
+++ b/test/org/apache/catalina/session/TestPersistentManagerDataSourceStore.java
@@ -87,7 +87,7 @@ public class TestPersistentManagerDataSourceStore extends TomcatBaseTest {
         ctx.setDistributable(true);
 
         Tomcat.addServlet(ctx, "DummyServlet", new DummyServlet());
-        ctx.addServletMappingDecoded("/dummy", "DummyServlet");
+        ctx.addServletMapping("/dummy", "DummyServlet");
 
         PersistentManager manager = new PersistentManager();
         DerbyDataSourceStore store = new DerbyDataSourceStore("basictest");
diff --git a/test/org/apache/catalina/session/TestPersistentManagerFileStore.java b/test/org/apache/catalina/session/TestPersistentManagerFileStore.java
index e59be587c8..425d17222d 100644
--- a/test/org/apache/catalina/session/TestPersistentManagerFileStore.java
+++ b/test/org/apache/catalina/session/TestPersistentManagerFileStore.java
@@ -73,7 +73,7 @@ public class TestPersistentManagerFileStore extends TomcatBaseTest {
         ctx.setDistributable(true);
 
         Tomcat.addServlet(ctx, "DummyServlet", new DummyServlet());
-        ctx.addServletMappingDecoded("/dummy", "DummyServlet");
+        ctx.addServletMapping("/dummy", "DummyServlet");
 
         PersistentManager manager = new PersistentManager();
         FileStore store = new FileStore();
diff --git a/test/org/apache/catalina/session/TestPersistentManagerIntegration.java b/test/org/apache/catalina/session/TestPersistentManagerIntegration.java
index bd4fac340e..5a409b955f 100644
--- a/test/org/apache/catalina/session/TestPersistentManagerIntegration.java
+++ b/test/org/apache/catalina/session/TestPersistentManagerIntegration.java
@@ -78,7 +78,7 @@ public class TestPersistentManagerIntegration extends TomcatBaseTest {
         ctx.setDistributable(true);
 
         Tomcat.addServlet(ctx, "DummyServlet", new DummyServlet());
-        ctx.addServletMappingDecoded("/dummy", "DummyServlet");
+        ctx.addServletMapping("/dummy", "DummyServlet");
 
         PersistentManager manager = new PersistentManager();
         TesterStore store = new TesterStore();
@@ -111,7 +111,7 @@ public class TestPersistentManagerIntegration extends TomcatBaseTest {
         ctx.setDistributable(true);
 
         Tomcat.addServlet(ctx, "DummyServlet", new DummyServlet());
-        ctx.addServletMappingDecoded("/dummy", "DummyServlet");
+        ctx.addServletMapping("/dummy", "DummyServlet");
 
         PersistentManager manager = new PersistentManager();
         TesterStore store = new TesterStore();
@@ -144,7 +144,7 @@ public class TestPersistentManagerIntegration extends TomcatBaseTest {
         ctx.setDistributable(true);
 
         Tomcat.addServlet(ctx, "DummyServlet", new DummyServlet());
-        ctx.addServletMappingDecoded("/dummy", "DummyServlet");
+        ctx.addServletMapping("/dummy", "DummyServlet");
 
         PersistentManager manager = new PersistentManager();
         TesterStore store = new TesterStore();
diff --git a/test/org/apache/catalina/session/TestStandardSessionAccessor.java b/test/org/apache/catalina/session/TestStandardSessionAccessor.java
index 44764da3bb..34f0e2c8a9 100644
--- a/test/org/apache/catalina/session/TestStandardSessionAccessor.java
+++ b/test/org/apache/catalina/session/TestStandardSessionAccessor.java
@@ -48,7 +48,7 @@ public class TestStandardSessionAccessor extends TomcatBaseTest {
         CountDownLatch latch = new CountDownLatch(1);
 
         Tomcat.addServlet(ctx, "accessor", new AccessorServlet(latch));
-        ctx.addServletMappingDecoded("/accessor", "accessor");
+        ctx.addServletMapping("/accessor", "accessor");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/session/TestStandardSessionIntegration.java b/test/org/apache/catalina/session/TestStandardSessionIntegration.java
index 1e83e78e63..c1de34c281 100644
--- a/test/org/apache/catalina/session/TestStandardSessionIntegration.java
+++ b/test/org/apache/catalina/session/TestStandardSessionIntegration.java
@@ -59,7 +59,7 @@ public class TestStandardSessionIntegration extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug56578", new Bug56578Servlet());
-        ctx.addServletMappingDecoded("/bug56578", "bug56578");
+        ctx.addServletMapping("/bug56578", "bug56578");
 
         if (useClustering) {
             SimpleTcpCluster cluster = new SimpleTcpCluster();
diff --git a/test/org/apache/catalina/ssi/TestRegExpCapture.java b/test/org/apache/catalina/ssi/TestRegExpCapture.java
index d190cf206f..9a5ca501cf 100644
--- a/test/org/apache/catalina/ssi/TestRegExpCapture.java
+++ b/test/org/apache/catalina/ssi/TestRegExpCapture.java
@@ -76,7 +76,7 @@ public class TestRegExpCapture extends TomcatBaseTest {
         ssiFilter.setFilterClass(SSIFilter.class.getName());
         FilterMap ssiFilterMap = new FilterMap();
         ssiFilterMap.setFilterName("ssiFilter");
-        ssiFilterMap.addURLPatternDecoded("*.shtml");
+        ssiFilterMap.addURLPattern("*.shtml");
         ctx.addFilterDef(ssiFilter);
         ctx.addFilterMap(ssiFilterMap);
 
diff --git a/test/org/apache/catalina/ssi/TestSsiServlet.java b/test/org/apache/catalina/ssi/TestSsiServlet.java
index d18f04d87a..009caa5f3c 100644
--- a/test/org/apache/catalina/ssi/TestSsiServlet.java
+++ b/test/org/apache/catalina/ssi/TestSsiServlet.java
@@ -44,11 +44,11 @@ public class TestSsiServlet extends TomcatBaseTest {
         Context ctxt = tomcat.addContext("", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "default", new DefaultServlet());
-        ctxt.addServletMappingDecoded("/", "default");
+        ctxt.addServletMapping("/", "default");
 
         Wrapper ssi = Tomcat.addServlet(ctxt, "ssi", new SSIServlet());
         ssi.addInitParameter("allowExec", "true");
-        ctxt.addServletMappingDecoded("*.shtml", "ssi");
+        ctxt.addServletMapping("*.shtml", "ssi");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/startup/EmbeddedTomcat.java b/test/org/apache/catalina/startup/EmbeddedTomcat.java
index 4ac2b249b7..6aa8057873 100644
--- a/test/org/apache/catalina/startup/EmbeddedTomcat.java
+++ b/test/org/apache/catalina/startup/EmbeddedTomcat.java
@@ -67,7 +67,7 @@ public class EmbeddedTomcat {
         skipTldsForResourceJars(ctx);
         CounterServlet counterServlet = new CounterServlet();
         Tomcat.addServlet(ctx, "counterServlet", counterServlet);
-        ctx.addServletMappingDecoded("/", "counterServlet");
+        ctx.addServletMapping("/", "counterServlet");
         //ctx.addApplicationListener(new WsContextListener());
 
         tomcat.start();
diff --git a/test/org/apache/catalina/startup/TestContextConfig.java b/test/org/apache/catalina/startup/TestContextConfig.java
index 4b6b748349..93845f05b0 100644
--- a/test/org/apache/catalina/startup/TestContextConfig.java
+++ b/test/org/apache/catalina/startup/TestContextConfig.java
@@ -112,7 +112,7 @@ public class TestContextConfig extends TomcatBaseTest {
 
         Tomcat.addServlet(context, "TestServlet",
                 "org.apache.catalina.startup.TesterServletWithLifeCycleMethods");
-        context.addServletMappingDecoded("/testServlet", "TestServlet");
+        context.addServletMapping("/testServlet", "TestServlet");
 
         tomcat.enableNaming();
 
@@ -131,7 +131,7 @@ public class TestContextConfig extends TomcatBaseTest {
 
         Tomcat.addServlet(context, "TestServlet",
                 "org.apache.catalina.startup.TesterServletWithAnnotations");
-        context.addServletMappingDecoded("/testServlet", "TestServlet");
+        context.addServletMapping("/testServlet", "TestServlet");
 
         tomcat.enableNaming();
 
diff --git a/test/org/apache/catalina/startup/TestContextConfigAnnotation.java b/test/org/apache/catalina/startup/TestContextConfigAnnotation.java
index 69d13c37a7..ba2b80ac09 100644
--- a/test/org/apache/catalina/startup/TestContextConfigAnnotation.java
+++ b/test/org/apache/catalina/startup/TestContextConfigAnnotation.java
@@ -211,7 +211,7 @@ public class TestContextConfigAnnotation {
 
         webxml.addFilter(filterDef);
         FilterMap filterMap = new FilterMap();
-        filterMap.addURLPatternDecoded("/param1");
+        filterMap.addURLPattern("/param1");
         filterMap.setFilterName("paramFilter");
         webxml.addFilterMapping(filterMap);
 
diff --git a/test/org/apache/catalina/startup/TestPropertySources.java b/test/org/apache/catalina/startup/TestPropertySources.java
index bc9cae4353..b560dbc2f6 100644
--- a/test/org/apache/catalina/startup/TestPropertySources.java
+++ b/test/org/apache/catalina/startup/TestPropertySources.java
@@ -99,7 +99,7 @@ public class TestPropertySources extends LoggingBaseTest {
         Context ctx = tomcat.addContext("", null);
 
         Tomcat.addServlet(ctx, "myServlet", new HelloWorld());
-        ctx.addServletMappingDecoded("/", "myServlet");
+        ctx.addServletMapping("/", "myServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/startup/TestStartupIPv6Connectors.java b/test/org/apache/catalina/startup/TestStartupIPv6Connectors.java
index 14e7fc30db..3698bdbb68 100644
--- a/test/org/apache/catalina/startup/TestStartupIPv6Connectors.java
+++ b/test/org/apache/catalina/startup/TestStartupIPv6Connectors.java
@@ -128,7 +128,7 @@ public class TestStartupIPv6Connectors extends TomcatBaseTest {
         tomcat.setBaseDir(baseDir.getAbsolutePath());
         Context context = tomcat.addContext("", null);
         Tomcat.addServlet(context, "simple", new HelloWorldServlet());
-        context.addServletMappingDecoded("/", "simple");
+        context.addServletMapping("/", "simple");
 
         try {
             tomcat.start();
diff --git a/test/org/apache/catalina/startup/TestTomcat.java b/test/org/apache/catalina/startup/TestTomcat.java
index 32bd0084f1..6eaac6a07b 100644
--- a/test/org/apache/catalina/startup/TestTomcat.java
+++ b/test/org/apache/catalina/startup/TestTomcat.java
@@ -194,7 +194,7 @@ public class TestTomcat extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "myServlet", new HelloWorld());
-        ctx.addServletMappingDecoded("/", "myServlet");
+        ctx.addServletMapping("/", "myServlet");
 
         tomcat.start();
 
@@ -245,7 +245,7 @@ public class TestTomcat extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "myServlet", new HelloWorldSession());
-        ctx.addServletMappingDecoded("/", "myServlet");
+        ctx.addServletMapping("/", "myServlet");
 
         tomcat.start();
 
@@ -284,7 +284,7 @@ public class TestTomcat extends TomcatBaseTest {
         ctx.getNamingResources().addEnvironment(environment);
 
         Tomcat.addServlet(ctx, "jndiServlet", new HelloWorldJndi());
-        ctx.addServletMappingDecoded("/", "jndiServlet");
+        ctx.addServletMapping("/", "jndiServlet");
 
         tomcat.start();
 
@@ -318,7 +318,7 @@ public class TestTomcat extends TomcatBaseTest {
         ctx.getNamingResources().addResourceLink(link);
 
         Tomcat.addServlet(ctx, "jndiServlet", new HelloWorldJndi());
-        ctx.addServletMappingDecoded("/", "jndiServlet");
+        ctx.addServletMapping("/", "jndiServlet");
 
         tomcat.start();
 
@@ -343,7 +343,7 @@ public class TestTomcat extends TomcatBaseTest {
         ctx.addApplicationListener(WsContextListener.class.getName());
 
         Tomcat.addServlet(ctx, "testGetResource", new GetResource());
-        ctx.addServletMappingDecoded("/testGetResource", "testGetResource");
+        ctx.addServletMapping("/testGetResource", "testGetResource");
 
         tomcat.start();
 
@@ -383,7 +383,7 @@ public class TestTomcat extends TomcatBaseTest {
 
         InitCount initCount = new InitCount();
         Tomcat.addServlet(ctx, "initCount", initCount);
-        ctx.addServletMappingDecoded("/", "initCount");
+        ctx.addServletMapping("/", "initCount");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/startup/TestTomcatClassLoader.java b/test/org/apache/catalina/startup/TestTomcatClassLoader.java
index 6c1b0b4744..ea91a99905 100644
--- a/test/org/apache/catalina/startup/TestTomcatClassLoader.java
+++ b/test/org/apache/catalina/startup/TestTomcatClassLoader.java
@@ -43,7 +43,7 @@ public class TestTomcatClassLoader extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "ClassLoaderReport", new ClassLoaderReport(null));
-        ctx.addServletMappingDecoded("/", "ClassLoaderReport");
+        ctx.addServletMapping("/", "ClassLoaderReport");
 
         tomcat.start();
 
@@ -65,7 +65,7 @@ public class TestTomcatClassLoader extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "ClassLoaderReport", new ClassLoaderReport(cl));
-        ctx.addServletMappingDecoded("/", "ClassLoaderReport");
+        ctx.addServletMapping("/", "ClassLoaderReport");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/startup/TestTomcatStandalone.java b/test/org/apache/catalina/startup/TestTomcatStandalone.java
index f3abbf1fa2..a7323efe60 100644
--- a/test/org/apache/catalina/startup/TestTomcatStandalone.java
+++ b/test/org/apache/catalina/startup/TestTomcatStandalone.java
@@ -170,7 +170,7 @@ public class TestTomcatStandalone extends LoggingBaseTest {
             Context ctx = tomcat.addContext("", null);
 
             Tomcat.addServlet(ctx, "myServlet", new HelloWorld());
-            ctx.addServletMappingDecoded("/", "myServlet");
+            ctx.addServletMapping("/", "myServlet");
 
             tomcat.start();
             // Emulate Tomcat main thread
diff --git a/test/org/apache/catalina/valves/TestAccessLogValve.java b/test/org/apache/catalina/valves/TestAccessLogValve.java
index 2bfae1ae80..eaa33479e2 100644
--- a/test/org/apache/catalina/valves/TestAccessLogValve.java
+++ b/test/org/apache/catalina/valves/TestAccessLogValve.java
@@ -280,7 +280,7 @@ public class TestAccessLogValve extends TomcatBaseTest {
         // Map the test Servlet
         TesterServlet servlet = new TesterServlet();
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         CharArrayWriter writer = new CharArrayWriter();
         if (TEXT_TYPE.equals(type)) {
diff --git a/test/org/apache/catalina/valves/TestAccessLogValveFile.java b/test/org/apache/catalina/valves/TestAccessLogValveFile.java
index 0b27282416..3f27a43b09 100644
--- a/test/org/apache/catalina/valves/TestAccessLogValveFile.java
+++ b/test/org/apache/catalina/valves/TestAccessLogValveFile.java
@@ -239,7 +239,7 @@ public class TestAccessLogValveFile extends TomcatBaseTest {
         Tomcat tomcat = getTomcatInstance();
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         logDir = getLogDir();
         AccessLogValve valve = new AccessLogValve();
diff --git a/test/org/apache/catalina/valves/TestErrorReportValve.java b/test/org/apache/catalina/valves/TestErrorReportValve.java
index d4bdee420f..b3c3b1d207 100644
--- a/test/org/apache/catalina/valves/TestErrorReportValve.java
+++ b/test/org/apache/catalina/valves/TestErrorReportValve.java
@@ -51,7 +51,7 @@ public class TestErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "errorServlet", new ErrorServlet());
-        ctx.addServletMappingDecoded("/", "errorServlet");
+        ctx.addServletMapping("/", "errorServlet");
 
         tomcat.start();
 
@@ -84,7 +84,7 @@ public class TestErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug54220", new Bug54220Servlet(false));
-        ctx.addServletMappingDecoded("/", "bug54220");
+        ctx.addServletMapping("/", "bug54220");
 
         tomcat.start();
 
@@ -104,7 +104,7 @@ public class TestErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug54220", new Bug54220Servlet(true));
-        ctx.addServletMappingDecoded("/", "bug54220");
+        ctx.addServletMapping("/", "bug54220");
 
         tomcat.start();
 
@@ -147,7 +147,7 @@ public class TestErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug54536", new Bug54536Servlet());
-        ctx.addServletMappingDecoded("/", "bug54536");
+        ctx.addServletMapping("/", "bug54536");
 
         tomcat.start();
 
@@ -184,7 +184,7 @@ public class TestErrorReportValve extends TomcatBaseTest {
         Bug56042Servlet bug56042Servlet = new Bug56042Servlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "bug56042Servlet", bug56042Servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/bug56042Servlet", "bug56042Servlet");
+        ctx.addServletMapping("/bug56042Servlet", "bug56042Servlet");
 
         tomcat.start();
 
@@ -245,9 +245,9 @@ public class TestErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "exception", new ExceptionServlet());
-        ctx.addServletMappingDecoded("/exception", "exception");
+        ctx.addServletMapping("/exception", "exception");
         Tomcat.addServlet(ctx, "erropage", new ErrorPageServlet());
-        ctx.addServletMappingDecoded("/erropage", "erropage");
+        ctx.addServletMapping("/erropage", "erropage");
         ErrorPage errorPage = new ErrorPage();
         errorPage.setErrorCode(HttpServletResponse.SC_INTERNAL_SERVER_ERROR);
         errorPage.setLocation("/erropage");
diff --git a/test/org/apache/catalina/valves/TestExtendedAccessLogValve.java b/test/org/apache/catalina/valves/TestExtendedAccessLogValve.java
index 4f920f310b..d110410553 100644
--- a/test/org/apache/catalina/valves/TestExtendedAccessLogValve.java
+++ b/test/org/apache/catalina/valves/TestExtendedAccessLogValve.java
@@ -127,7 +127,7 @@ public class TestExtendedAccessLogValve extends TomcatBaseTest {
                 resp.getWriter().write("Test response");
             }
         });
-        ctx.addServletMappingDecoded("/test", "testServlet");
+        ctx.addServletMapping("/test", "testServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/valves/TestFilterValve.java b/test/org/apache/catalina/valves/TestFilterValve.java
index dd2d918c5c..2e15bd78fb 100644
--- a/test/org/apache/catalina/valves/TestFilterValve.java
+++ b/test/org/apache/catalina/valves/TestFilterValve.java
@@ -48,7 +48,7 @@ public class TestFilterValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         FilterValve valve = new FilterValve();
         valve.setFilterClass(PassthroughFilter.class.getName());
@@ -71,7 +71,7 @@ public class TestFilterValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         FilterValve valve = new FilterValve();
         valve.setFilterClass(BlockingFilter.class.getName());
@@ -92,7 +92,7 @@ public class TestFilterValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         FilterValve valve = new FilterValve();
         valve.setFilterClass(WrappingFilter.class.getName());
diff --git a/test/org/apache/catalina/valves/TestJsonErrorReportValve.java b/test/org/apache/catalina/valves/TestJsonErrorReportValve.java
index c3c4b316bf..2df82081fe 100644
--- a/test/org/apache/catalina/valves/TestJsonErrorReportValve.java
+++ b/test/org/apache/catalina/valves/TestJsonErrorReportValve.java
@@ -56,7 +56,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "sendError", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "Server broke"));
-        ctx.addServletMappingDecoded("/", "sendError");
+        ctx.addServletMapping("/", "sendError");
 
         tomcat.start();
 
@@ -93,7 +93,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "exception",
                 new ExceptionServlet("Something went wrong"));
-        ctx.addServletMappingDecoded("/", "exception");
+        ctx.addServletMapping("/", "exception");
 
         tomcat.start();
 
@@ -137,7 +137,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
         String specialMessage = "Error with \"quotes\" and \\backslash\\";
         Tomcat.addServlet(ctx, "specialChars", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, specialMessage));
-        ctx.addServletMappingDecoded("/", "specialChars");
+        ctx.addServletMapping("/", "specialChars");
 
         tomcat.start();
 
@@ -172,7 +172,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "customError",
                 new SendErrorServlet(999, "The sky is falling"));
-        ctx.addServletMappingDecoded("/", "customError");
+        ctx.addServletMapping("/", "customError");
 
         tomcat.start();
 
@@ -201,7 +201,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "notFound", new SendErrorServlet(
                 HttpServletResponse.SC_NOT_FOUND, "Resource not found"));
-        ctx.addServletMappingDecoded("/", "notFound");
+        ctx.addServletMapping("/", "notFound");
 
         tomcat.start();
 
@@ -232,7 +232,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "chained", new ChainedExceptionServlet());
-        ctx.addServletMappingDecoded("/", "chained");
+        ctx.addServletMapping("/", "chained");
 
         tomcat.start();
 
@@ -271,7 +271,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "noMessage", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, null));
-        ctx.addServletMappingDecoded("/", "noMessage");
+        ctx.addServletMapping("/", "noMessage");
 
         tomcat.start();
 
@@ -298,7 +298,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         tomcat.start();
 
@@ -322,7 +322,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
         String unicodeMessage = "Error: \u00e9\u00e8\u00ea \u4e2d\u6587 \u00f1";
         Tomcat.addServlet(ctx, "unicode", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, unicodeMessage));
-        ctx.addServletMappingDecoded("/", "unicode");
+        ctx.addServletMapping("/", "unicode");
 
         tomcat.start();
 
@@ -350,7 +350,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "sendError", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "Server broke"));
-        ctx.addServletMappingDecoded("/", "sendError");
+        ctx.addServletMapping("/", "sendError");
 
         tomcat.start();
 
@@ -386,7 +386,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "exception", new ExceptionServlet("Something went wrong"));
-        ctx.addServletMappingDecoded("/", "exception");
+        ctx.addServletMapping("/", "exception");
 
         tomcat.start();
 
@@ -421,7 +421,7 @@ public class TestJsonErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "unknownNoMessage", new SendErrorServlet(999, null));
-        ctx.addServletMappingDecoded("/", "unknownNoMessage");
+        ctx.addServletMapping("/", "unknownNoMessage");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/valves/TestParameterLimitValve.java b/test/org/apache/catalina/valves/TestParameterLimitValve.java
index 6956fcdf89..3240c97d1d 100644
--- a/test/org/apache/catalina/valves/TestParameterLimitValve.java
+++ b/test/org/apache/catalina/valves/TestParameterLimitValve.java
@@ -59,7 +59,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         parameterLimitValve.setUrlPatternLimits("/special/.*=2");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/special/endpoint", "snoop");
+        ctx.addServletMapping("/special/endpoint", "snoop");
 
         tomcat.start();
 
@@ -146,7 +146,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         parameterLimitValve.setUrlPatternLimits("/special====2");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/special===", "snoop");
+        ctx.addServletMapping("/special===", "snoop");
 
         tomcat.start();
 
@@ -168,7 +168,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         parameterLimitValve.setUrlPatternLimits("/special%20endpoint=2");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/special endpoint", "snoop");
+        ctx.addServletMapping("/special endpoint", "snoop");
 
         tomcat.start();
 
@@ -192,10 +192,10 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         parameterLimitValve.setUrlPatternLimits("/special/.*=2" + CRLF + "/special2/.*=3" + CRLF + "/my/special/url1=1");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/special/endpoint", "snoop");
-        ctx.addServletMappingDecoded("/special2/endpoint", "snoop");
-        ctx.addServletMappingDecoded("/my/special/url1", "snoop");
-        ctx.addServletMappingDecoded("/my/special/url2", "snoop");
+        ctx.addServletMapping("/special/endpoint", "snoop");
+        ctx.addServletMapping("/special2/endpoint", "snoop");
+        ctx.addServletMapping("/my/special/url1", "snoop");
+        ctx.addServletMapping("/my/special/url2", "snoop");
 
         tomcat.start();
 
@@ -253,7 +253,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         parameterLimitValve.setUrlPatternLimits("/special/.*=2");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/other/endpoint", "snoop");
+        ctx.addServletMapping("/other/endpoint", "snoop");
 
         tomcat.start();
 
@@ -284,7 +284,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         }
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/api/test", "snoop");
+        ctx.addServletMapping("/api/test", "snoop");
 
         tomcat.start();
 
@@ -310,7 +310,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         }
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/api/test", "snoop");
+        ctx.addServletMapping("/api/test", "snoop");
 
         tomcat.start();
 
@@ -340,8 +340,8 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         }
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/api/test", "snoop");
-        ctx.addServletMappingDecoded("/admin/test", "snoop");
+        ctx.addServletMapping("/api/test", "snoop");
+        ctx.addServletMapping("/admin/test", "snoop");
 
         tomcat.start();
 
@@ -369,7 +369,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         parameterLimitValve.setUrlPatternLimits("/.*=2");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/special/endpoint", "snoop");
+        ctx.addServletMapping("/special/endpoint", "snoop");
 
         tomcat.start();
 
@@ -413,13 +413,13 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         context3ParameterLimitValve.setUrlPatternLimits("/special/.*=1");
 
         Tomcat.addServlet(ctx1, "snoop", new SnoopServlet());
-        ctx1.addServletMappingDecoded("/special/endpoint", "snoop");
+        ctx1.addServletMapping("/special/endpoint", "snoop");
 
         Tomcat.addServlet(ctx2, "snoop", new SnoopServlet());
-        ctx2.addServletMappingDecoded("/special/endpoint", "snoop");
+        ctx2.addServletMapping("/special/endpoint", "snoop");
 
         Tomcat.addServlet(ctx3, "snoop", new SnoopServlet());
-        ctx3.addServletMappingDecoded("/special/endpoint", "snoop");
+        ctx3.addServletMapping("/special/endpoint", "snoop");
 
         tomcat.start();
 
@@ -486,7 +486,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         Wrapper w = Tomcat.addServlet(ctx, "multipart", new MultipartServlet());
         // Use defaults for Multipart
         w.setMultipartConfigElement(new MultipartConfigElement(""));
-        ctx.addServletMappingDecoded("/upload/*", "multipart");
+        ctx.addServletMapping("/upload/*", "multipart");
 
         tomcat.start();
 
@@ -596,7 +596,7 @@ public class TestParameterLimitValve extends TomcatBaseTest {
         Wrapper w = Tomcat.addServlet(ctx, "multipart", new MultipartServlet());
         // Use defaults for Multipart
         w.setMultipartConfigElement(new MultipartConfigElement(""));
-        ctx.addServletMappingDecoded("/upload/*", "multipart");
+        ctx.addServletMapping("/upload/*", "multipart");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/valves/TestPersistentValveAsync.java b/test/org/apache/catalina/valves/TestPersistentValveAsync.java
index 73cfd92d21..a29a9ba11c 100644
--- a/test/org/apache/catalina/valves/TestPersistentValveAsync.java
+++ b/test/org/apache/catalina/valves/TestPersistentValveAsync.java
@@ -60,7 +60,7 @@ public class TestPersistentValveAsync extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(context, "async-complete", new AsyncCompleteServlet());
         wrapper.setAsyncSupported(true);
-        context.addServletMappingDecoded("/async-complete", "async-complete");
+        context.addServletMapping("/async-complete", "async-complete");
 
         TesterStore store = new TesterStore();
         PersistentManager manager = configurePersistentManager(context, store, new PersistentValve());
@@ -84,7 +84,7 @@ public class TestPersistentValveAsync extends TomcatBaseTest {
 
         Wrapper wrapper = Tomcat.addServlet(context, "async-dispatch", new AsyncDispatchServlet());
         wrapper.setAsyncSupported(true);
-        context.addServletMappingDecoded("/async-dispatch", "async-dispatch");
+        context.addServletMapping("/async-dispatch", "async-dispatch");
 
         TesterStore store = new TesterStore();
         PersistentManager manager = configurePersistentManager(context, store, new PersistentValve());
@@ -139,7 +139,7 @@ public class TestPersistentValveAsync extends TomcatBaseTest {
         StandardContext context = addSemaphoreTestServlets("async-error",
                 new ErrorDispatchingAsyncServlet(asyncStarted, allowAsyncError), "/async-error");
         Tomcat.addServlet(context, "async-error-target", new ErrorServlet());
-        context.addServletMappingDecoded("/async-error-target", "async-error-target");
+        context.addServletMapping("/async-error-target", "async-error-target");
         tomcat.start();
 
         assertSemaphoreHeldUntilAsyncRequestCompletes("/async-error", asyncStarted, allowAsyncError,
@@ -178,11 +178,11 @@ public class TestPersistentValveAsync extends TomcatBaseTest {
         context.setDistributable(true);
 
         Tomcat.addServlet(context, "session", new SessionServlet());
-        context.addServletMappingDecoded("/session", "session");
+        context.addServletMapping("/session", "session");
 
         Wrapper asyncWrapper = Tomcat.addServlet(context, asyncServletName, asyncServlet);
         asyncWrapper.setAsyncSupported(true);
-        context.addServletMappingDecoded(asyncPath, asyncServletName);
+        context.addServletMapping(asyncPath, asyncServletName);
 
         TesterStore store = new TesterStore();
         PersistentValve persistentValve = new PersistentValve();
diff --git a/test/org/apache/catalina/valves/TestProxyErrorReportValve.java b/test/org/apache/catalina/valves/TestProxyErrorReportValve.java
index ded0896ade..416ba915b7 100644
--- a/test/org/apache/catalina/valves/TestProxyErrorReportValve.java
+++ b/test/org/apache/catalina/valves/TestProxyErrorReportValve.java
@@ -52,12 +52,12 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "error", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "Server broke"));
-        ctx.addServletMappingDecoded("/", "error");
+        ctx.addServletMapping("/", "error");
 
         // Register an error page at the Host's error report valve level
         // so findErrorPage() returns a URL for the redirect
         Tomcat.addServlet(ctx, "errorPage", new ErrorPageServlet());
-        ctx.addServletMappingDecoded("/error-page", "errorPage");
+        ctx.addServletMapping("/error-page", "errorPage");
 
         tomcat.start();
 
@@ -89,10 +89,10 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "error", new SendErrorServlet(
                 HttpServletResponse.SC_NOT_FOUND, "Not found"));
-        ctx.addServletMappingDecoded("/", "error");
+        ctx.addServletMapping("/", "error");
 
         Tomcat.addServlet(ctx, "errorPage", new ErrorPageServlet());
-        ctx.addServletMappingDecoded("/error-page", "errorPage");
+        ctx.addServletMapping("/error-page", "errorPage");
 
         tomcat.start();
 
@@ -126,7 +126,7 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "error", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "No page configured"));
-        ctx.addServletMappingDecoded("/", "error");
+        ctx.addServletMapping("/", "error");
 
         tomcat.start();
 
@@ -151,7 +151,7 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         tomcat.start();
 
@@ -172,7 +172,7 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "notFound", new SendErrorServlet(
                 HttpServletResponse.SC_NOT_FOUND, "Resource not found"));
-        ctx.addServletMappingDecoded("/", "notFound");
+        ctx.addServletMapping("/", "notFound");
 
         tomcat.start();
 
@@ -213,7 +213,7 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "error", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, customErrorMessage));
-        ctx.addServletMappingDecoded("/", "error");
+        ctx.addServletMapping("/", "error");
 
         tomcat.start();
 
@@ -237,7 +237,7 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "exception", new ExceptionServlet());
-        ctx.addServletMappingDecoded("/", "exception");
+        ctx.addServletMapping("/", "exception");
 
         tomcat.start();
 
@@ -262,10 +262,10 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "sendError", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "Server broke"));
-        ctx.addServletMappingDecoded("/", "sendError");
+        ctx.addServletMapping("/", "sendError");
 
         Tomcat.addServlet(ctx, "errorPage", new ErrorPageServlet());
-        ctx.addServletMappingDecoded("/error-page", "errorPage");
+        ctx.addServletMapping("/error-page", "errorPage");
 
         tomcat.start();
 
@@ -311,7 +311,7 @@ public class TestProxyErrorReportValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "sendError", new SendErrorServlet(
                 HttpServletResponse.SC_INTERNAL_SERVER_ERROR, "Server broke"));
-        ctx.addServletMappingDecoded("/", "sendError");
+        ctx.addServletMapping("/", "sendError");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/valves/TestSemaphoreValve.java b/test/org/apache/catalina/valves/TestSemaphoreValve.java
index cf9ae9d92a..dc186b477d 100644
--- a/test/org/apache/catalina/valves/TestSemaphoreValve.java
+++ b/test/org/apache/catalina/valves/TestSemaphoreValve.java
@@ -49,7 +49,7 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         SemaphoreValve valve = new SemaphoreValve();
         valve.setConcurrency(10);
@@ -71,7 +71,7 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         SemaphoreValve valve = new SemaphoreValve();
         valve.setConcurrency(10);
@@ -97,7 +97,7 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         CountDownLatch insideServlet = new CountDownLatch(1);
         CountDownLatch canReturn = new CountDownLatch(1);
         Tomcat.addServlet(ctx, "slow", new SlowServlet(insideServlet, canReturn));
-        ctx.addServletMappingDecoded("/", "slow");
+        ctx.addServletMapping("/", "slow");
 
         SemaphoreValve valve = new SemaphoreValve();
         valve.setConcurrency(1);
@@ -144,7 +144,7 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         CountDownLatch insideServlet = new CountDownLatch(1);
         CountDownLatch canReturn = new CountDownLatch(1);
         Tomcat.addServlet(ctx, "slow", new SlowServlet(insideServlet, canReturn));
-        ctx.addServletMappingDecoded("/", "slow");
+        ctx.addServletMapping("/", "slow");
 
         SemaphoreValve valve = new SemaphoreValve();
         valve.setConcurrency(1);
@@ -214,7 +214,7 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         SemaphoreValve valve = new SemaphoreValve();
         valve.setConcurrency(5);
@@ -243,7 +243,7 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         CountDownLatch insideServlet = new CountDownLatch(1);
         CountDownLatch canReturn = new CountDownLatch(1);
         Tomcat.addServlet(ctx, "slow", new SlowServlet(insideServlet, canReturn));
-        ctx.addServletMappingDecoded("/", "slow");
+        ctx.addServletMapping("/", "slow");
 
         SemaphoreValve valve = new SemaphoreValve();
         valve.setConcurrency(1);
@@ -300,10 +300,10 @@ public class TestSemaphoreValve extends TomcatBaseTest {
         CountDownLatch insideServlet = new CountDownLatch(1);
         CountDownLatch canReturn = new CountDownLatch(1);
         Tomcat.addServlet(ctx, "slow", new SlowServlet(insideServlet, canReturn));
-        ctx.addServletMappingDecoded("/slow", "slow");
+        ctx.addServletMapping("/slow", "slow");
 
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/bypass", "hello");
+        ctx.addServletMapping("/bypass", "hello");
 
         SemaphoreValve valve = new SemaphoreValve() {
             @Override
diff --git a/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java b/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java
index ecf67047d5..a6cd6b0c9c 100644
--- a/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java
+++ b/test/org/apache/catalina/valves/rewrite/TestRewriteValve.java
@@ -909,12 +909,12 @@ public class TestRewriteValve extends TomcatBaseTest {
         rewriteValve.setConfiguration(config);
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/a/Z", "snoop");
-        ctx.addServletMappingDecoded("/a/%5A", "snoop");
-        ctx.addServletMappingDecoded("/c/*", "snoop");
-        ctx.addServletMappingDecoded("/W/*", "snoop");
+        ctx.addServletMapping("/a/Z", "snoop");
+        ctx.addServletMapping("/a/%5A", "snoop");
+        ctx.addServletMapping("/c/*", "snoop");
+        ctx.addServletMapping("/W/*", "snoop");
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -965,8 +965,8 @@ public class TestRewriteValve extends TomcatBaseTest {
         rewriteValve.setConfiguration(config);
 
         Tomcat.addServlet(ctx, "tester", new TesterServlet());
-        ctx.addServletMappingDecoded("/from/a", "tester");
-        ctx.addServletMappingDecoded("/to/b", "tester");
+        ctx.addServletMapping("/from/a", "tester");
+        ctx.addServletMapping("/to/b", "tester");
 
         tomcat.start();
 
@@ -1007,7 +1007,7 @@ public class TestRewriteValve extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "cookieTest", new CookieTestServlet());
 
-        ctx.addServletMappingDecoded("/", "cookieTest");
+        ctx.addServletMapping("/", "cookieTest");
 
         tomcat.start();
 
@@ -1132,7 +1132,7 @@ public class TestRewriteValve extends TomcatBaseTest {
         rewriteValve.setConfiguration("RewriteRule ^/source/(.*)$ /target/$1");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/target/*", "snoop");
+        ctx.addServletMapping("/target/*", "snoop");
 
         tomcat.start();
 
@@ -1165,7 +1165,7 @@ public class TestRewriteValve extends TomcatBaseTest {
                 "RewriteRule ^(.*) /blocked$1 [R]");
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/other", "snoop");
+        ctx.addServletMapping("/other", "snoop");
 
         tomcat.start();
 
diff --git a/test/org/apache/catalina/webresources/TestWebResourceContentType.java b/test/org/apache/catalina/webresources/TestWebResourceContentType.java
index 6f74f54760..69984cc458 100644
--- a/test/org/apache/catalina/webresources/TestWebResourceContentType.java
+++ b/test/org/apache/catalina/webresources/TestWebResourceContentType.java
@@ -55,7 +55,7 @@ public class TestWebResourceContentType extends TomcatBaseTest {
 
         // Add custom default servlet
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/*", "default");
+        ctx.addServletMapping("/*", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/TestAbstractProtocol.java b/test/org/apache/coyote/TestAbstractProtocol.java
index 9b3129fac9..b61eafa951 100644
--- a/test/org/apache/coyote/TestAbstractProtocol.java
+++ b/test/org/apache/coyote/TestAbstractProtocol.java
@@ -69,7 +69,7 @@ public class TestAbstractProtocol extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/TestIoTimeouts.java b/test/org/apache/coyote/TestIoTimeouts.java
index 243f75dc9f..8fc6b09844 100644
--- a/test/org/apache/coyote/TestIoTimeouts.java
+++ b/test/org/apache/coyote/TestIoTimeouts.java
@@ -93,7 +93,7 @@ public class TestIoTimeouts extends TomcatBaseTest {
             Context root = tomcat.addContext("", TEMP_DIR);
             Wrapper w = Tomcat.addServlet(root, "Test", new NonBlockingEchoServlet());
             w.setAsyncSupported(true);
-            root.addServletMappingDecoded("/test", "Test");
+            root.addServletMapping("/test", "Test");
 
             try {
                 tomcat.start();
diff --git a/test/org/apache/coyote/TestResponse.java b/test/org/apache/coyote/TestResponse.java
index b88737f1d6..522d30e2e9 100644
--- a/test/org/apache/coyote/TestResponse.java
+++ b/test/org/apache/coyote/TestResponse.java
@@ -48,7 +48,7 @@ public class TestResponse extends TomcatBaseTest {
 
         // Add  servlet
         Tomcat.addServlet(ctx, "CharsetServlet", new CharsetServlet());
-        ctx.addServletMappingDecoded("/*", "CharsetServlet");
+        ctx.addServletMapping("/*", "CharsetServlet");
 
         tomcat.start();
 
@@ -99,7 +99,7 @@ public class TestResponse extends TomcatBaseTest {
 
         // Add  servlet
         Tomcat.addServlet(ctx, "ContentTypeServlet", new ContentTypeServlet());
-        ctx.addServletMappingDecoded("/*", "ContentTypeServlet");
+        ctx.addServletMapping("/*", "ContentTypeServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java b/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java
index 79f5d81de0..95eddbd16e 100644
--- a/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java
+++ b/test/org/apache/coyote/ajp/TestAbstractAjpProcessor.java
@@ -95,7 +95,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/", "snoop");
+        ctx.addServletMapping("/", "snoop");
 
         SimpleAjpClient ajpClient = new SimpleAjpClient(ajpPacketSize);
 
@@ -512,7 +512,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "helloWorld", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "helloWorld");
+        ctx.addServletMapping("/", "helloWorld");
 
         StringManager smClient = StringManager.getManager("org.apache.catalina.valves");
         String expectedBody = "<p><b>" + smClient.getString("errorReportValve.type") + "</b> " +
@@ -576,7 +576,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "helloWorld", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "helloWorld");
+        ctx.addServletMapping("/", "helloWorld");
 
         SimpleAjpClient ajpClient = new SimpleAjpClient();
 
@@ -683,7 +683,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug55453", new Tester304WithBodyServlet());
-        ctx.addServletMappingDecoded("/", "bug55453");
+        ctx.addServletMapping("/", "bug55453");
 
         tomcat.start();
 
@@ -738,7 +738,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
 
         ReadBodyServlet servlet = new ReadBodyServlet(callAvailable);
         Tomcat.addServlet(ctx, "ReadBody", servlet);
-        ctx.addServletMappingDecoded("/", "ReadBody");
+        ctx.addServletMapping("/", "ReadBody");
 
         tomcat.start();
 
@@ -793,7 +793,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
 
         FixedResponseSizeServlet servlet = new FixedResponseSizeServlet(15000, 16000);
         Tomcat.addServlet(ctx, "FixedResponseSizeServlet", servlet);
-        ctx.addServletMappingDecoded("/", "FixedResponseSizeServlet");
+        ctx.addServletMapping("/", "FixedResponseSizeServlet");
 
         tomcat.start();
 
@@ -834,7 +834,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug66512", new InvalidHeaderServlet());
-        ctx.addServletMappingDecoded("/", "bug66512");
+        ctx.addServletMapping("/", "bug66512");
 
         tomcat.start();
 
@@ -897,7 +897,7 @@ public class TestAbstractAjpProcessor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "bug66591", new NoHeadersServlet());
-        ctx.addServletMappingDecoded("/", "bug66591");
+        ctx.addServletMapping("/", "bug66591");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/TestHttp11InputBuffer.java b/test/org/apache/coyote/http11/TestHttp11InputBuffer.java
index 7772c1aaa6..6533ba6c1c 100644
--- a/test/org/apache/coyote/http11/TestHttp11InputBuffer.java
+++ b/test/org/apache/coyote/http11/TestHttp11InputBuffer.java
@@ -67,7 +67,7 @@ public class TestHttp11InputBuffer extends TomcatBaseTest {
 
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "Bug48839", new Bug48839Servlet());
-            root.addServletMappingDecoded("/test", "Bug48839");
+            root.addServletMapping("/test", "Bug48839");
 
             try {
                 tomcat.start();
@@ -306,7 +306,7 @@ public class TestHttp11InputBuffer extends TomcatBaseTest {
 
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "Bug51557", new Bug51557Servlet(headerName));
-            root.addServletMappingDecoded("/test", "Bug51557");
+            root.addServletMapping("/test", "Bug51557");
 
             try {
                 Connector connector = tomcat.getConnector();
@@ -440,7 +440,7 @@ public class TestHttp11InputBuffer extends TomcatBaseTest {
 
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "test", new TesterServlet());
-            root.addServletMappingDecoded("/test", "test");
+            root.addServletMapping("/test", "test");
 
             try {
                 tomcat.start();
@@ -511,7 +511,7 @@ public class TestHttp11InputBuffer extends TomcatBaseTest {
 
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "Bug54947", new TesterServlet());
-            root.addServletMappingDecoded("/test", "Bug54947");
+            root.addServletMapping("/test", "Bug54947");
 
             try {
                 tomcat.start();
@@ -704,7 +704,7 @@ public class TestHttp11InputBuffer extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/TestHttp11InputBufferCRLF.java b/test/org/apache/coyote/http11/TestHttp11InputBufferCRLF.java
index 4747605f34..4be93270a0 100644
--- a/test/org/apache/coyote/http11/TestHttp11InputBufferCRLF.java
+++ b/test/org/apache/coyote/http11/TestHttp11InputBufferCRLF.java
@@ -159,7 +159,7 @@ public class TestHttp11InputBufferCRLF extends TomcatBaseTest {
 
             Context root = tomcat.addContext("", TEMP_DIR);
             Tomcat.addServlet(root, "TesterServlet", new TesterServlet());
-            root.addServletMappingDecoded("/test", "TesterServlet");
+            root.addServletMapping("/test", "TesterServlet");
 
             try {
                 tomcat.start();
diff --git a/test/org/apache/coyote/http11/TestHttp11OutputBuffer.java b/test/org/apache/coyote/http11/TestHttp11OutputBuffer.java
index 4f63cb13f6..11f2b618e8 100644
--- a/test/org/apache/coyote/http11/TestHttp11OutputBuffer.java
+++ b/test/org/apache/coyote/http11/TestHttp11OutputBuffer.java
@@ -45,7 +45,7 @@ public class TestHttp11OutputBuffer extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "echo", new EchoBodyServlet());
-        ctx.addServletMappingDecoded("/echo", "echo");
+        ctx.addServletMapping("/echo", "echo");
 
         tomcat.start();
 
@@ -93,7 +93,7 @@ public class TestHttp11OutputBuffer extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "header", new HeaderServlet(customHeaderValue));
-        ctx.addServletMappingDecoded("/header", "header");
+        ctx.addServletMapping("/header", "header");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/TestHttp11Processor.java b/test/org/apache/coyote/http11/TestHttp11Processor.java
index 9363c43d06..2f7dedf113 100644
--- a/test/org/apache/coyote/http11/TestHttp11Processor.java
+++ b/test/org/apache/coyote/http11/TestHttp11Processor.java
@@ -81,7 +81,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctx, "ChunkedResponseWithErrorServlet", new ResponseWithErrorServlet(true));
-        ctx.addServletMappingDecoded("/*", "ChunkedResponseWithErrorServlet");
+        ctx.addServletMapping("/*", "ChunkedResponseWithErrorServlet");
 
         tomcat.start();
 
@@ -318,7 +318,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add protected servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -374,7 +374,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         // Add protected servlet
         Wrapper w = Tomcat.addServlet(ctx, "servlet", new Bug64974Servlet());
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/foo", "servlet");
+        ctx.addServletMapping("/foo", "servlet");
 
         tomcat.start();
 
@@ -417,7 +417,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "NoContentLengthFlushingServlet", new NoContentLengthFlushingServlet());
-        ctx.addServletMappingDecoded("/test", "NoContentLengthFlushingServlet");
+        ctx.addServletMapping("/test", "NoContentLengthFlushingServlet");
 
         tomcat.start();
 
@@ -441,7 +441,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         Tomcat.addServlet(ctx, "NoContentLengthConnectionCloseFlushingServlet",
                 new NoContentLengthConnectionCloseFlushingServlet());
-        ctx.addServletMappingDecoded("/test", "NoContentLengthConnectionCloseFlushingServlet");
+        ctx.addServletMapping("/test", "NoContentLengthConnectionCloseFlushingServlet");
 
         tomcat.start();
 
@@ -476,7 +476,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "LargeHeaderServlet", new LargeHeaderServlet(flush));
-        ctx.addServletMappingDecoded("/test", "LargeHeaderServlet");
+        ctx.addServletMapping("/test", "LargeHeaderServlet");
 
         tomcat.start();
 
@@ -509,7 +509,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "async", new Bug55772Servlet());
-        ctx.addServletMappingDecoded("/*", "async");
+        ctx.addServletMapping("/*", "async");
 
         tomcat.start();
 
@@ -572,10 +572,10 @@ public class TestHttp11Processor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "echo", new EchoBodyServlet());
-        ctx.addServletMappingDecoded("/echo", "echo");
+        ctx.addServletMapping("/echo", "echo");
 
         SecurityCollection collection = new SecurityCollection("All", "");
-        collection.addPatternDecoded("/*");
+        collection.addPattern("/*");
         SecurityConstraint constraint = new SecurityConstraint();
         constraint.addAuthRole("Any");
         constraint.addCollection(collection);
@@ -744,7 +744,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         Context root = getProgrammaticRootContext();
         Wrapper w = Tomcat.addServlet(root, "Bug57621", new Bug57621Servlet(delayAsyncThread));
         w.setAsyncSupported(true);
-        root.addServletMappingDecoded("/test", "Bug57621");
+        root.addServletMapping("/test", "Bug57621");
 
         tomcat.start();
 
@@ -850,7 +850,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "Bug59310", new Bug59310Servlet());
-        ctx.addServletMappingDecoded("/test", "Bug59310");
+        ctx.addServletMapping("/test", "Bug59310");
 
         tomcat.start();
 
@@ -905,7 +905,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
         DispatchingServlet servlet = new DispatchingServlet();
         Wrapper w = Tomcat.addServlet(ctx, "Test", servlet);
         w.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/test", "Test");
+        ctx.addServletMapping("/test", "Test");
 
         tomcat.start();
 
@@ -993,7 +993,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         Bug61086Servlet servlet = new Bug61086Servlet();
         Tomcat.addServlet(ctx, "Test", servlet);
-        ctx.addServletMappingDecoded("/test", "Test");
+        ctx.addServletMapping("/test", "Test");
 
         tomcat.start();
 
@@ -1033,7 +1033,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1071,7 +1071,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1106,7 +1106,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1135,7 +1135,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1169,7 +1169,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1203,7 +1203,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1240,7 +1240,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1277,7 +1277,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1314,7 +1314,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1352,7 +1352,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new ServerNameTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1391,7 +1391,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new ServerNameTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1431,7 +1431,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new ServerNameTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1470,7 +1470,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new ServerNameTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1510,7 +1510,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new ServerNameTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1550,7 +1550,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new ServerNameTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1646,7 +1646,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet(explicitClose));
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1762,7 +1762,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new SwallowBodyTesterServlet());
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1922,7 +1922,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet(false));
-        ctx.addServletMappingDecoded("/foo", "TesterServlet");
+        ctx.addServletMapping("/foo", "TesterServlet");
 
         tomcat.start();
 
@@ -1989,7 +1989,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "TestPostNoReadServlet", new TestPostNoReadServlet());
-        ctx.addServletMappingDecoded("/foo", "TestPostNoReadServlet");
+        ctx.addServletMapping("/foo", "TestPostNoReadServlet");
 
         tomcat.start();
 
@@ -2061,7 +2061,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "EarlyHintsServlet", new EarlyHintsServlet());
-        ctx.addServletMappingDecoded("/ehs", "EarlyHintsServlet");
+        ctx.addServletMapping("/ehs", "EarlyHintsServlet");
 
         tomcat.start();
 
@@ -2093,7 +2093,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "EarlyHintsServlet", new EarlyHintsServlet(true, null));
-        ctx.addServletMappingDecoded("/ehs", "EarlyHintsServlet");
+        ctx.addServletMapping("/ehs", "EarlyHintsServlet");
 
         tomcat.start();
 
@@ -2126,7 +2126,7 @@ public class TestHttp11Processor extends TomcatBaseTest {
 
         // Add servlet
         Tomcat.addServlet(ctx, "EarlyHintsServlet", new EarlyHintsServlet(true, "ignored"));
-        ctx.addServletMappingDecoded("/ehs", "EarlyHintsServlet");
+        ctx.addServletMapping("/ehs", "EarlyHintsServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/TestHttp11ProcessorDoHead.java b/test/org/apache/coyote/http11/TestHttp11ProcessorDoHead.java
index fc7967a83c..92ca2c136c 100644
--- a/test/org/apache/coyote/http11/TestHttp11ProcessorDoHead.java
+++ b/test/org/apache/coyote/http11/TestHttp11ProcessorDoHead.java
@@ -101,7 +101,7 @@ public class TestHttp11ProcessorDoHead extends TomcatBaseTest {
             w.addInitParameter(HttpServlet.LEGACY_DO_HEAD, "true");
         }
 
-        ctx.addServletMappingDecoded("/head", "DoHeadServlet");
+        ctx.addServletMapping("/head", "DoHeadServlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/filters/TestChunkedInputFilter.java b/test/org/apache/coyote/http11/filters/TestChunkedInputFilter.java
index 7d0ed6e677..4fe19cc53f 100644
--- a/test/org/apache/coyote/http11/filters/TestChunkedInputFilter.java
+++ b/test/org/apache/coyote/http11/filters/TestChunkedInputFilter.java
@@ -114,7 +114,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
 
         EchoHeaderServlet servlet = new EchoHeaderServlet(expectPass);
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -196,7 +196,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
 
         BodyReadServlet servlet = new BodyReadServlet(false, Integer.MAX_VALUE);
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -226,7 +226,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new CommitResponseServlet());
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -291,7 +291,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new EchoHeaderServlet(false));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         // Limit the size of the trailing header
         Assert.assertTrue(tomcat.getConnector().setProperty("maxTrailerSize", Integer.toString(trailerSizeLimit)));
@@ -387,7 +387,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new EchoHeaderServlet(ok));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -437,7 +437,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new EchoHeaderServlet(true));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -538,7 +538,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
 
         BodyReadServlet servlet = new BodyReadServlet(expectPass, readLimit);
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -612,7 +612,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new SwallowBodyServlet(swallowException));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -817,7 +817,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new SwallowBodyServlet(false));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -876,7 +876,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new TesterServlet(false));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
@@ -1039,7 +1039,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
 
         BodyReadLineServlet servlet = new BodyReadLineServlet();
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/test", "servlet");
+        ctx.addServletMapping("/test", "servlet");
 
         tomcat.getConnector().setProperty("connectionTimeout", "300000");
         tomcat.start();
@@ -1093,7 +1093,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         NonBlockingReadLineServlet servlet = new NonBlockingReadLineServlet();
         Wrapper wrapper = Tomcat.addServlet(ctx, "servlet", servlet);
         wrapper.setAsyncSupported(true);
-        ctx.addServletMappingDecoded("/test", "servlet");
+        ctx.addServletMapping("/test", "servlet");
 
         tomcat.getConnector().setProperty("connectionTimeout", "300000");
         tomcat.start();
@@ -1189,7 +1189,7 @@ public class TestChunkedInputFilter extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
 
         Tomcat.addServlet(ctx, "servlet", new EchoHeaderServlet(ok));
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/upgrade/TestUpgrade.java b/test/org/apache/coyote/http11/upgrade/TestUpgrade.java
index f3969cb036..8502eb7a34 100644
--- a/test/org/apache/coyote/http11/upgrade/TestUpgrade.java
+++ b/test/org/apache/coyote/http11/upgrade/TestUpgrade.java
@@ -170,7 +170,7 @@ public class TestUpgrade extends TomcatBaseTest {
 
         UpgradeServlet servlet = new UpgradeServlet(upgradeHandlerClass);
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http11/upgrade/TestUpgradeInternalHandler.java b/test/org/apache/coyote/http11/upgrade/TestUpgradeInternalHandler.java
index 8daab7ffdf..66100761ff 100644
--- a/test/org/apache/coyote/http11/upgrade/TestUpgradeInternalHandler.java
+++ b/test/org/apache/coyote/http11/upgrade/TestUpgradeInternalHandler.java
@@ -90,7 +90,7 @@ public class TestUpgradeInternalHandler extends TomcatBaseTest {
 
         UpgradeServlet servlet = new UpgradeServlet(upgradeHandlerClass);
         Tomcat.addServlet(ctx, "servlet", servlet);
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http2/Http2TestBase.java b/test/org/apache/coyote/http2/Http2TestBase.java
index e2a0eea8fd..27521a8d16 100644
--- a/test/org/apache/coyote/http2/Http2TestBase.java
+++ b/test/org/apache/coyote/http2/Http2TestBase.java
@@ -670,15 +670,15 @@ public abstract class Http2TestBase extends TomcatBaseTest {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "empty", new EmptyServlet());
-        ctxt.addServletMappingDecoded("/empty", "empty");
+        ctxt.addServletMapping("/empty", "empty");
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "large", new LargeServlet());
-        ctxt.addServletMappingDecoded("/large", "large");
+        ctxt.addServletMapping("/large", "large");
         Tomcat.addServlet(ctxt, "cookie", new CookieServlet());
-        ctxt.addServletMappingDecoded("/cookie", "cookie");
+        ctxt.addServletMapping("/cookie", "cookie");
         Tomcat.addServlet(ctxt, "parameter", new ParameterServlet());
-        ctxt.addServletMappingDecoded("/parameter", "parameter");
+        ctxt.addServletMapping("/parameter", "parameter");
 
         tomcat.start();
     }
diff --git a/test/org/apache/coyote/http2/TestAsync.java b/test/org/apache/coyote/http2/TestAsync.java
index 9e4e41c801..af8fb8f482 100644
--- a/test/org/apache/coyote/http2/TestAsync.java
+++ b/test/org/apache/coyote/http2/TestAsync.java
@@ -107,10 +107,10 @@ public class TestAsync extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "async", new AsyncServlet(blockCount, useNonContainerThreadForWrite));
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
         tomcat.start();
 
         int startingWindowSize;
diff --git a/test/org/apache/coyote/http2/TestAsyncError.java b/test/org/apache/coyote/http2/TestAsyncError.java
index 813a489543..a44c05c820 100644
--- a/test/org/apache/coyote/http2/TestAsyncError.java
+++ b/test/org/apache/coyote/http2/TestAsyncError.java
@@ -54,10 +54,10 @@ public class TestAsyncError extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "async", asyncErrorServlet);
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
         tomcat.start();
 
         openClientConnection();
diff --git a/test/org/apache/coyote/http2/TestAsyncFlush.java b/test/org/apache/coyote/http2/TestAsyncFlush.java
index a99d0fbb57..bc60861b02 100644
--- a/test/org/apache/coyote/http2/TestAsyncFlush.java
+++ b/test/org/apache/coyote/http2/TestAsyncFlush.java
@@ -64,10 +64,10 @@ public class TestAsyncFlush extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "async", new AsyncFlushServlet(blockCount));
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
         tomcat.start();
 
         openClientConnection();
diff --git a/test/org/apache/coyote/http2/TestAsyncReadListener.java b/test/org/apache/coyote/http2/TestAsyncReadListener.java
index 8d47883cd5..0bba39f8eb 100644
--- a/test/org/apache/coyote/http2/TestAsyncReadListener.java
+++ b/test/org/apache/coyote/http2/TestAsyncReadListener.java
@@ -96,10 +96,10 @@ public class TestAsyncReadListener extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "async", asyncServlet);
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
         tomcat.start();
     }
 
diff --git a/test/org/apache/coyote/http2/TestAsyncTimeout.java b/test/org/apache/coyote/http2/TestAsyncTimeout.java
index 8f0a457f17..ef8f95de64 100644
--- a/test/org/apache/coyote/http2/TestAsyncTimeout.java
+++ b/test/org/apache/coyote/http2/TestAsyncTimeout.java
@@ -48,7 +48,7 @@ public class TestAsyncTimeout extends Http2TestBase {
         Context ctxt = getProgrammaticRootContext();
         // This is the target of the HTTP/2 upgrade request
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         // This is the servlet that does that actual test
         // This latch is used to signal that that async thread used by the test
@@ -57,7 +57,7 @@ public class TestAsyncTimeout extends Http2TestBase {
         CountDownLatch latch = new CountDownLatch(1);
         Wrapper w = Tomcat.addServlet(ctxt, "async", new AsyncTimeoutServlet(latch));
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
         tomcat.start();
 
         openClientConnection();
diff --git a/test/org/apache/coyote/http2/TestCancelledUpload.java b/test/org/apache/coyote/http2/TestCancelledUpload.java
index ed317f27bd..91efe679a8 100644
--- a/test/org/apache/coyote/http2/TestCancelledUpload.java
+++ b/test/org/apache/coyote/http2/TestCancelledUpload.java
@@ -141,7 +141,7 @@ public class TestCancelledUpload extends Http2TestBase {
         // Retain '/simple' url-pattern since it enables code re-use
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "cancel", new CancelServlet());
-        ctxt.addServletMappingDecoded("/simple", "cancel");
+        ctxt.addServletMapping("/simple", "cancel");
 
         tomcat.start();
     }
diff --git a/test/org/apache/coyote/http2/TestHttp2AccessLogs.java b/test/org/apache/coyote/http2/TestHttp2AccessLogs.java
index e355ff72bc..d6a63a3bb8 100644
--- a/test/org/apache/coyote/http2/TestHttp2AccessLogs.java
+++ b/test/org/apache/coyote/http2/TestHttp2AccessLogs.java
@@ -46,10 +46,10 @@ public class TestHttp2AccessLogs extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "trailers", new TrailersServlet());
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/trailers", "trailers");
+        ctxt.addServletMapping("/trailers", "trailers");
         TesterAccessLogValve valve = new TesterAccessLogValve(writer);
         valve.setPattern("%{header-key}o %{trailer-key}o");
         tomcat.getHost().getPipeline().addValve(valve);
diff --git a/test/org/apache/coyote/http2/TestHttp2UpgradeHandler.java b/test/org/apache/coyote/http2/TestHttp2UpgradeHandler.java
index c36ef53374..d754e6e721 100644
--- a/test/org/apache/coyote/http2/TestHttp2UpgradeHandler.java
+++ b/test/org/apache/coyote/http2/TestHttp2UpgradeHandler.java
@@ -37,9 +37,9 @@ public class TestHttp2UpgradeHandler extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "large", new LargeHeaderServlet());
-        ctxt.addServletMappingDecoded("/large", "large");
+        ctxt.addServletMapping("/large", "large");
 
         tomcat.start();
 
@@ -145,7 +145,7 @@ public class TestHttp2UpgradeHandler extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "ReadRequestBodyServlet", new ReadRequestBodyServlet());
-        ctxt.addServletMappingDecoded("/", "ReadRequestBodyServlet");
+        ctxt.addServletMapping("/", "ReadRequestBodyServlet");
 
         if (tooBig) {
             // Reduce maxSavePostSize rather than use a larger request body
@@ -203,7 +203,7 @@ public class TestHttp2UpgradeHandler extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http2/TestLargeUpload.java b/test/org/apache/coyote/http2/TestLargeUpload.java
index d82c82fb4e..438f8cf83c 100644
--- a/test/org/apache/coyote/http2/TestLargeUpload.java
+++ b/test/org/apache/coyote/http2/TestLargeUpload.java
@@ -127,7 +127,7 @@ public class TestLargeUpload extends Http2TestBase {
         // Retain '/simple' url-pattern since it enables code re-use
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "read", new DataReadServlet());
-        ctxt.addServletMappingDecoded("/simple", "read");
+        ctxt.addServletMapping("/simple", "read");
 
         tomcat.start();
     }
diff --git a/test/org/apache/coyote/http2/TestStandardSessionIntegrationHttp2.java b/test/org/apache/coyote/http2/TestStandardSessionIntegrationHttp2.java
index 7661310f3e..1a3e3a812b 100644
--- a/test/org/apache/coyote/http2/TestStandardSessionIntegrationHttp2.java
+++ b/test/org/apache/coyote/http2/TestStandardSessionIntegrationHttp2.java
@@ -48,10 +48,10 @@ public class TestStandardSessionIntegrationHttp2 extends Http2TestBase {
         Context ctxt = getProgrammaticRootContext();
         // Need simple servlet for the HTTP upgrade
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         // Servlet for this test
         Tomcat.addServlet(ctxt, "session", new SessionServlet());
-        ctxt.addServletMappingDecoded("/session", "session");
+        ctxt.addServletMapping("/session", "session");
         tomcat.start();
 
         openClientConnection();
diff --git a/test/org/apache/coyote/http2/TestStream.java b/test/org/apache/coyote/http2/TestStream.java
index 9ca9a926b7..5503d3be05 100644
--- a/test/org/apache/coyote/http2/TestStream.java
+++ b/test/org/apache/coyote/http2/TestStream.java
@@ -47,9 +47,9 @@ public class TestStream extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "pathparam", new PathParam());
-        ctxt.addServletMappingDecoded("/pathparam", "pathparam");
+        ctxt.addServletMapping("/pathparam", "pathparam");
 
         tomcat.start();
 
@@ -81,9 +81,9 @@ public class TestStream extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "trailers", new ResponseTrailers());
-        ctxt.addServletMappingDecoded("/trailers", "trailers");
+        ctxt.addServletMapping("/trailers", "trailers");
 
         tomcat.start();
 
diff --git a/test/org/apache/coyote/http2/TestStreamProcessor.java b/test/org/apache/coyote/http2/TestStreamProcessor.java
index 25a40b1283..e65f15feed 100644
--- a/test/org/apache/coyote/http2/TestStreamProcessor.java
+++ b/test/org/apache/coyote/http2/TestStreamProcessor.java
@@ -55,10 +55,10 @@ public class TestStreamProcessor extends Http2TestBase {
         // logic from the super class.
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "async", new AsyncComplete());
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
 
         tomcat.start();
 
@@ -94,10 +94,10 @@ public class TestStreamProcessor extends Http2TestBase {
         // logic from the super class.
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Wrapper w = Tomcat.addServlet(ctxt, "async", new AsyncDispatch());
         w.setAsyncSupported(true);
-        ctxt.addServletMappingDecoded("/async", "async");
+        ctxt.addServletMapping("/async", "async");
 
         tomcat.start();
 
@@ -126,7 +126,7 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.start();
 
@@ -178,9 +178,9 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "noContent", new NoContentServlet());
-        ctxt.addServletMappingDecoded("/noContent", "noContent");
+        ctxt.addServletMapping("/noContent", "noContent");
 
 
         tomcat.start();
@@ -226,7 +226,7 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.start();
 
@@ -270,7 +270,7 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.start();
 
@@ -312,7 +312,7 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.start();
 
@@ -356,7 +356,7 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.start();
 
@@ -400,7 +400,7 @@ public class TestStreamProcessor extends Http2TestBase {
         Context ctxt = tomcat.addWebapp(null, "", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
 
         tomcat.getConnector().setProperty("relaxedQueryChars", "[]");
 
@@ -501,9 +501,9 @@ public class TestStreamProcessor extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "compression", new CompressionServlet());
-        ctxt.addServletMappingDecoded("/compression", "compression");
+        ctxt.addServletMapping("/compression", "compression");
 
         // Enable compression
         Connector connector = tomcat.getConnector();
@@ -595,9 +595,9 @@ public class TestStreamProcessor extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "ehs", new EarlyHintsServlet());
-        ctxt.addServletMappingDecoded("/ehs", "ehs");
+        ctxt.addServletMapping("/ehs", "ehs");
         tomcat.start();
 
         openClientConnection();
@@ -660,9 +660,9 @@ public class TestStreamProcessor extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "server", new ServerHeaderServlet());
-        ctxt.addServletMappingDecoded("/server", "server");
+        ctxt.addServletMapping("/server", "server");
         tomcat.start();
 
         openClientConnection();
@@ -703,9 +703,9 @@ public class TestStreamProcessor extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "server", new ServerHeaderServlet());
-        ctxt.addServletMappingDecoded("/server", "server");
+        ctxt.addServletMapping("/server", "server");
         tomcat.start();
 
         openClientConnection();
@@ -743,9 +743,9 @@ public class TestStreamProcessor extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "simple", new SimpleServlet());
-        ctxt.addServletMappingDecoded("/simple", "simple");
+        ctxt.addServletMapping("/simple", "simple");
         Tomcat.addServlet(ctxt, "server", new ServerHeaderServlet());
-        ctxt.addServletMappingDecoded("/server", "server");
+        ctxt.addServletMapping("/server", "server");
         tomcat.start();
 
         openClientConnection();
diff --git a/test/org/apache/coyote/http2/TestStreamQueryString.java b/test/org/apache/coyote/http2/TestStreamQueryString.java
index 90a2d4d199..f5148b8cdd 100644
--- a/test/org/apache/coyote/http2/TestStreamQueryString.java
+++ b/test/org/apache/coyote/http2/TestStreamQueryString.java
@@ -76,7 +76,7 @@ public class TestStreamQueryString extends Http2TestBase {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "query", new Query(queryValue));
-        ctxt.addServletMappingDecoded("/query", "query");
+        ctxt.addServletMapping("/query", "query");
 
         tomcat.start();
 
diff --git a/test/org/apache/jasper/runtime/TestPageContextImpl.java b/test/org/apache/jasper/runtime/TestPageContextImpl.java
index ee326ec3b2..9883009335 100644
--- a/test/org/apache/jasper/runtime/TestPageContextImpl.java
+++ b/test/org/apache/jasper/runtime/TestPageContextImpl.java
@@ -64,7 +64,7 @@ public class TestPageContextImpl extends TomcatBaseTest {
 
         // Add the Servlet
         Tomcat.addServlet(ctx, "bug56010", new Bug56010());
-        ctx.addServletMappingDecoded("/bug56010", "bug56010");
+        ctx.addServletMapping("/bug56010", "bug56010");
 
         tomcat.start();
 
diff --git a/test/org/apache/jasper/servlet/TestJspServlet.java b/test/org/apache/jasper/servlet/TestJspServlet.java
index 8f5558254e..f395166889 100644
--- a/test/org/apache/jasper/servlet/TestJspServlet.java
+++ b/test/org/apache/jasper/servlet/TestJspServlet.java
@@ -47,7 +47,7 @@ public class TestJspServlet  extends TomcatBaseTest {
 
         // Create a servlet that always throws an exception for a PUT request
         Tomcat.addServlet(context, "Bug56568Servlet", new Bug56568aServlet());
-        context.addServletMappingDecoded("/bug56568", "Bug56568Servlet");
+        context.addServletMapping("/bug56568", "Bug56568Servlet");
 
         // Configure a JSP page to handle the 500 error response
         // The JSP page will see the same method as the original request (PUT)
diff --git a/test/org/apache/juli/TestPerWebappJuliIntegration.java b/test/org/apache/juli/TestPerWebappJuliIntegration.java
index eab7be4825..f8e281f604 100644
--- a/test/org/apache/juli/TestPerWebappJuliIntegration.java
+++ b/test/org/apache/juli/TestPerWebappJuliIntegration.java
@@ -109,7 +109,7 @@ public class TestPerWebappJuliIntegration extends TomcatBaseTest {
                 resp.getWriter().print(Logger.getLogger("").getLevel());
             }
         });
-        context.addServletMappingDecoded("/log_level", "log_level");
+        context.addServletMapping("/log_level", "log_level");
     }
     private ConstructAppResult constructAppForHandlerIsolationTest(Tomcat tomcat, String appId, Level logLevel) throws FileNotFoundException {
         File appDir = new File(getTemporaryDirectory(), "juliHandler" + appId);
@@ -139,7 +139,7 @@ public class TestPerWebappJuliIntegration extends TomcatBaseTest {
                 root.info("JULI-" + appId + "-INFO");
             }
         });
-        context.addServletMappingDecoded("/test", "test");
+        context.addServletMapping("/test", "test");
         return new ConstructAppResult(logsDir, context);
     }
     private record ConstructAppResult(File logsDir, Context context) {}
diff --git a/test/org/apache/naming/TestEnvEntry.java b/test/org/apache/naming/TestEnvEntry.java
index 4a16e42e12..045b1fd5b8 100644
--- a/test/org/apache/naming/TestEnvEntry.java
+++ b/test/org/apache/naming/TestEnvEntry.java
@@ -118,7 +118,7 @@ public class TestEnvEntry extends TomcatBaseTest {
         Context context = tomcat.addWebapp(null, "/test", appDir.getAbsolutePath());
 
         Tomcat.addServlet(context, "InjectionServlet", "org.apache.naming.TesterInjectionServlet");
-        context.addServletMappingDecoded("/injection", "InjectionServlet");
+        context.addServletMapping("/injection", "InjectionServlet");
 
         tomcat.enableNaming();
         tomcat.start();
diff --git a/test/org/apache/naming/resources/TestNamingContext.java b/test/org/apache/naming/resources/TestNamingContext.java
index 445ce70f5f..387d07be3b 100644
--- a/test/org/apache/naming/resources/TestNamingContext.java
+++ b/test/org/apache/naming/resources/TestNamingContext.java
@@ -72,7 +72,7 @@ public class TestNamingContext extends TomcatBaseTest {
         // Map the test Servlet
         Bug49994Servlet bug49994Servlet = new Bug49994Servlet();
         Tomcat.addServlet(ctx, "bug49994Servlet", bug49994Servlet);
-        ctx.addServletMappingDecoded("/", "bug49994Servlet");
+        ctx.addServletMapping("/", "bug49994Servlet");
 
         tomcat.start();
 
@@ -132,7 +132,7 @@ public class TestNamingContext extends TomcatBaseTest {
         // Map the test Servlet
         Bug23950Servlet bug23950Servlet = new Bug23950Servlet();
         Tomcat.addServlet(ctx, "bug23950Servlet", bug23950Servlet);
-        ctx.addServletMappingDecoded("/", "bug23950Servlet");
+        ctx.addServletMapping("/", "bug23950Servlet");
 
         tomcat.start();
 
@@ -184,7 +184,7 @@ public class TestNamingContext extends TomcatBaseTest {
         // Map the test Servlet
         Bug50351Servlet bug50351Servlet = new Bug50351Servlet();
         Tomcat.addServlet(ctx, "bug50351Servlet", bug50351Servlet);
-        ctx.addServletMappingDecoded("/", "bug50351Servlet");
+        ctx.addServletMapping("/", "bug50351Servlet");
 
         tomcat.start();
 
@@ -237,7 +237,7 @@ public class TestNamingContext extends TomcatBaseTest {
         // Map the test Servlet
         Bug51744Servlet bug51744Servlet = new Bug51744Servlet();
         Tomcat.addServlet(ctx, "bug51744Servlet", bug51744Servlet);
-        ctx.addServletMappingDecoded("/", "bug51744Servlet");
+        ctx.addServletMapping("/", "bug51744Servlet");
 
         tomcat.start();
 
@@ -300,7 +300,7 @@ public class TestNamingContext extends TomcatBaseTest {
         // Map the test Servlet
         Bug52830Servlet bug52830Servlet = new Bug52830Servlet();
         Tomcat.addServlet(ctx, "bug52830Servlet", bug52830Servlet);
-        ctx.addServletMappingDecoded("/", "bug52830Servlet");
+        ctx.addServletMapping("/", "bug52830Servlet");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/integration/httpd/HttpdIntegrationBaseTest.java b/test/org/apache/tomcat/integration/httpd/HttpdIntegrationBaseTest.java
index fd488857b4..045d02fe34 100644
--- a/test/org/apache/tomcat/integration/httpd/HttpdIntegrationBaseTest.java
+++ b/test/org/apache/tomcat/integration/httpd/HttpdIntegrationBaseTest.java
@@ -118,7 +118,7 @@ public abstract class HttpdIntegrationBaseTest extends TomcatBaseTest {
             ctx.getPipeline().addValve(valve);
         }
         Tomcat.addServlet(ctx, SERVLET_NAME, new SnoopServlet());
-        ctx.addServletMappingDecoded("/" + SERVLET_NAME, SERVLET_NAME);
+        ctx.addServletMapping("/" + SERVLET_NAME, SERVLET_NAME);
         tomcat.start();
         tomcatPort = getPort();
     }
diff --git a/test/org/apache/tomcat/integration/httpd/TestErrorHandling.java b/test/org/apache/tomcat/integration/httpd/TestErrorHandling.java
index f6601ccc05..3c7ca13045 100644
--- a/test/org/apache/tomcat/integration/httpd/TestErrorHandling.java
+++ b/test/org/apache/tomcat/integration/httpd/TestErrorHandling.java
@@ -73,7 +73,7 @@ public class TestErrorHandling extends HttpdIntegrationBaseTest {
                 throw new ServletException("Expected error");
             }
         });
-        ctx.addServletMappingDecoded("/error", "error");
+        ctx.addServletMapping("/error", "error");
         int rc = getUrl("http://localhost:" + getHttpdPort() + "/error", new ByteChunk(), false);
         Assert.assertEquals(HttpServletResponse.SC_INTERNAL_SERVER_ERROR, rc);
     }
diff --git a/test/org/apache/tomcat/security/TestSecurity2017Ocsp.java b/test/org/apache/tomcat/security/TestSecurity2017Ocsp.java
index 570d7510ff..04b3e1429a 100644
--- a/test/org/apache/tomcat/security/TestSecurity2017Ocsp.java
+++ b/test/org/apache/tomcat/security/TestSecurity2017Ocsp.java
@@ -79,7 +79,7 @@ public class TestSecurity2017Ocsp extends OcspBaseTest {
         Context ctx = tomcat.addContext("", null);
 
         Tomcat.addServlet(ctx, "simple", new SimpleServlet());
-        ctx.addServletMappingDecoded("/simple", "simple");
+        ctx.addServletMapping("/simple", "simple");
 
         // Use the default (valid, non-revoked) server certificate
         TesterSupport.initSsl(tomcat, useOpenSSLTrust);
diff --git a/test/org/apache/tomcat/security/TestSecurity2018.java b/test/org/apache/tomcat/security/TestSecurity2018.java
index e9c62760f7..74b36824aa 100644
--- a/test/org/apache/tomcat/security/TestSecurity2018.java
+++ b/test/org/apache/tomcat/security/TestSecurity2018.java
@@ -56,7 +56,7 @@ public class TestSecurity2018 extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/security/TestSecurity2019.java b/test/org/apache/tomcat/security/TestSecurity2019.java
index f4c4744709..cc502af25f 100644
--- a/test/org/apache/tomcat/security/TestSecurity2019.java
+++ b/test/org/apache/tomcat/security/TestSecurity2019.java
@@ -57,7 +57,7 @@ public class TestSecurity2019 extends TomcatBaseTest {
         Context ctx = tomcat.addContext("", appDir.getAbsolutePath());
 
         Tomcat.addServlet(ctx, "ssi", new SSIServlet());
-        ctx.addServletMappingDecoded("*.shtml", "ssi");
+        ctx.addServletMapping("*.shtml", "ssi");
 
         ctx.setPrivileged(true);
 
@@ -92,11 +92,11 @@ public class TestSecurity2019 extends TomcatBaseTest {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName("ssi");
-        filterMap.addURLPatternDecoded("*.shtml");
+        filterMap.addURLPattern("*.shtml");
         ctx.addFilterMap(filterMap);
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
         ctx.addMimeMapping("shtml", "text/x-server-parsed-html");
 
         ctx.setPrivileged(true);
@@ -164,7 +164,7 @@ public class TestSecurity2019 extends TomcatBaseTest {
         cgi.addInitParameter("cgiPathPrefix", "WEB-INF/cgi");
         cgi.addInitParameter("executable", "");
         cgi.addInitParameter("enableCmdLineArguments", "true");
-        ctx.addServletMappingDecoded("/cgi/*", "cgi");
+        ctx.addServletMapping("/cgi/*", "cgi");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/security/TestSecurity2023.java b/test/org/apache/tomcat/security/TestSecurity2023.java
index 0bedbc9c48..df503f5327 100644
--- a/test/org/apache/tomcat/security/TestSecurity2023.java
+++ b/test/org/apache/tomcat/security/TestSecurity2023.java
@@ -73,7 +73,7 @@ public class TestSecurity2023 extends TomcatBaseTest {
         Context context = tomcat.addContext("", null);
         Wrapper wrapper = Tomcat.addServlet(context, "test", new TestServlet());
         wrapper.setMultipartConfigElement(new MultipartConfigElement(""));
-        context.addServletMappingDecoded("/", "test");
+        context.addServletMapping("/", "test");
 
         tomcat.start();
 
@@ -122,11 +122,11 @@ public class TestSecurity2023 extends TomcatBaseTest {
         tomcat.addRole("admin", "admin");
 
         Tomcat.addServlet(context, "login", new TestServlet());
-        context.addServletMappingDecoded("/login", "login");
+        context.addServletMapping("/login", "login");
         Tomcat.addServlet(context, "secret", new TestServlet());
-        context.addServletMappingDecoded("/secret.html", "secret");
+        context.addServletMapping("/secret.html", "secret");
         Tomcat.addServlet(context, "example", new TestServlet());
-        context.addServletMappingDecoded("/example.com", "example");
+        context.addServletMapping("/example.com", "example");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/unittest/TesterContext.java b/test/org/apache/tomcat/unittest/TesterContext.java
index ed61ec51b4..5badf1c1fd 100644
--- a/test/org/apache/tomcat/unittest/TesterContext.java
+++ b/test/org/apache/tomcat/unittest/TesterContext.java
@@ -783,6 +783,13 @@ public class TesterContext implements Context {
     }
 
     @Override
+    public void addServletMapping(String pattern, String name,
+            boolean jspWildcard) {
+        // NO-OP
+    }
+
+    @Override
+    @Deprecated
     public void addServletMappingDecoded(String pattern, String name,
             boolean jspWildcard) {
         // NO-OP
diff --git a/test/org/apache/tomcat/util/descriptor/web/TestJspPropertyGroupDescriptorImpl.java b/test/org/apache/tomcat/util/descriptor/web/TestJspPropertyGroupDescriptorImpl.java
index 15ce498a8e..4266ed8896 100644
--- a/test/org/apache/tomcat/util/descriptor/web/TestJspPropertyGroupDescriptorImpl.java
+++ b/test/org/apache/tomcat/util/descriptor/web/TestJspPropertyGroupDescriptorImpl.java
@@ -42,7 +42,7 @@ public class TestJspPropertyGroupDescriptorImpl {
     @Test
     public void testUrlPatternsAreIsolated() {
         JspPropertyGroup jpg = new JspPropertyGroup();
-        jpg.addUrlPatternDecoded("pattern");
+        jpg.addUrlPattern("pattern");
         JspPropertyGroupDescriptorImpl descriptor = new JspPropertyGroupDescriptorImpl(jpg);
         descriptor.getUrlPatterns().clear();
         Assert.assertEquals(1, descriptor.getUrlPatterns().size());
diff --git a/test/org/apache/tomcat/util/descriptor/web/TestSecurityConstraint.java b/test/org/apache/tomcat/util/descriptor/web/TestSecurityConstraint.java
index 0320c35ba5..a780aa2953 100644
--- a/test/org/apache/tomcat/util/descriptor/web/TestSecurityConstraint.java
+++ b/test/org/apache/tomcat/util/descriptor/web/TestSecurityConstraint.java
@@ -52,7 +52,7 @@ public class TestSecurityConstraint {
         GET_ONLY.addAuthRole(ROLE1);
         SecurityCollection scGetOnly = new SecurityCollection();
         scGetOnly.addMethod(Method.GET);
-        scGetOnly.addPatternDecoded(URL_PATTERN);
+        scGetOnly.addPattern(URL_PATTERN);
         scGetOnly.setName("GET-ONLY");
         GET_ONLY.addCollection(scGetOnly);
 
@@ -60,7 +60,7 @@ public class TestSecurityConstraint {
         POST_ONLY.addAuthRole(ROLE1);
         SecurityCollection scPostOnly = new SecurityCollection();
         scPostOnly.addMethod(Method.POST);
-        scPostOnly.addPatternDecoded(URL_PATTERN);
+        scPostOnly.addPattern(URL_PATTERN);
         scPostOnly.setName("POST_ONLY");
         POST_ONLY.addCollection(scPostOnly);
 
@@ -68,7 +68,7 @@ public class TestSecurityConstraint {
         GET_OMIT.addAuthRole(ROLE1);
         SecurityCollection scGetOmit = new SecurityCollection();
         scGetOmit.addOmittedMethod(Method.GET);
-        scGetOmit.addPatternDecoded(URL_PATTERN);
+        scGetOmit.addPattern(URL_PATTERN);
         scGetOmit.setName("GET_OMIT");
         GET_OMIT.addCollection(scGetOmit);
 
@@ -76,7 +76,7 @@ public class TestSecurityConstraint {
         POST_OMIT.addAuthRole(ROLE1);
         SecurityCollection scPostOmit = new SecurityCollection();
         scPostOmit.addOmittedMethod(Method.POST);
-        scPostOmit.addPatternDecoded(URL_PATTERN);
+        scPostOmit.addPattern(URL_PATTERN);
         scPostOmit.setName("POST_OMIT");
         POST_OMIT.addCollection(scPostOmit);
     }
diff --git a/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java b/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java
index 811cc91e46..ab33f8c049 100644
--- a/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java
+++ b/test/org/apache/tomcat/util/descriptor/web/TestWebXml.java
@@ -291,7 +291,7 @@ public class TestWebXml {
 
         FilterMap filterMap = new FilterMap();
         filterMap.setFilterName("Dummy");
-        filterMap.addURLPatternDecoded("/*");
+        filterMap.addURLPattern("/*");
         webXmlDefaultFragment.addFilterMapping(filterMap);
 
         // Listeners were added in 2.3 so should be excluded in 2.2
@@ -336,7 +336,7 @@ public class TestWebXml {
         sc.setDisplayName("dummy");
         SecurityCollection collection = new SecurityCollection();
         collection.setName("dummy");
-        collection.addPatternDecoded("/*");
+        collection.addPattern("/*");
         collection.addMethod(Method.DELETE);
         sc.addCollection(collection);
         webXmlDefaultFragment.addSecurityConstraint(sc);
@@ -533,6 +533,7 @@ public class TestWebXml {
     }
 
 
+    @SuppressWarnings("deprecation")
     @Test
     public void testEncoding() {
         WebXml webXml = new WebXml();
diff --git a/test/org/apache/tomcat/util/http/TestCookieParsing.java b/test/org/apache/tomcat/util/http/TestCookieParsing.java
index ff8c799c7f..91f062968b 100644
--- a/test/org/apache/tomcat/util/http/TestCookieParsing.java
+++ b/test/org/apache/tomcat/util/http/TestCookieParsing.java
@@ -177,7 +177,7 @@ public class TestCookieParsing extends TomcatBaseTest {
             } else {
                 Tomcat.addServlet(root, "Cookies", new EchoCookies());
             }
-            root.addServletMappingDecoded("/test", "Cookies");
+            root.addServletMapping("/test", "Cookies");
 
             tomcat.start();
             // Open connection
diff --git a/test/org/apache/tomcat/util/http/TestCookieProcessorGenerationHttp.java b/test/org/apache/tomcat/util/http/TestCookieProcessorGenerationHttp.java
index a057807b46..abbd1684ba 100644
--- a/test/org/apache/tomcat/util/http/TestCookieProcessorGenerationHttp.java
+++ b/test/org/apache/tomcat/util/http/TestCookieProcessorGenerationHttp.java
@@ -47,7 +47,7 @@ public class TestCookieProcessorGenerationHttp extends TomcatBaseTest {
         Map<String,String> cookies = new HashMap<>();
         cookies.put("Test", "\u0120");
         Tomcat.addServlet(ctx, "test", new CookieServlet(cookies));
-        ctx.addServletMappingDecoded("/test", "test");
+        ctx.addServletMapping("/test", "test");
         tomcat.start();
 
         Map<String,List<String>> headers = new HashMap<>();
@@ -99,7 +99,7 @@ public class TestCookieProcessorGenerationHttp extends TomcatBaseTest {
         cookies.put("aaa", "zzz");
         cookies.put("aAa", "yyy");
         Tomcat.addServlet(ctx, "test", new CookieServlet(cookies));
-        ctx.addServletMappingDecoded("/test", "test");
+        ctx.addServletMapping("/test", "test");
         tomcat.start();
 
         Map<String,List<String>> headers = new HashMap<>();
diff --git a/test/org/apache/tomcat/util/http/TestMimeHeadersIntegration.java b/test/org/apache/tomcat/util/http/TestMimeHeadersIntegration.java
index 118294c61c..1d403b40de 100644
--- a/test/org/apache/tomcat/util/http/TestMimeHeadersIntegration.java
+++ b/test/org/apache/tomcat/util/http/TestMimeHeadersIntegration.java
@@ -53,7 +53,7 @@ public class TestMimeHeadersIntegration extends TomcatBaseTest {
                 res.getWriter().write("OK");
             }
         });
-        ctx.addServletMappingDecoded("/", "servlet");
+        ctx.addServletMapping("/", "servlet");
 
         alv = new HeaderCountLogValve();
         tomcat.getHost().getPipeline().addValve(alv);
diff --git a/test/org/apache/tomcat/util/net/TestAlpnFallback.java b/test/org/apache/tomcat/util/net/TestAlpnFallback.java
index 45f6fbf7a2..ad162547c8 100644
--- a/test/org/apache/tomcat/util/net/TestAlpnFallback.java
+++ b/test/org/apache/tomcat/util/net/TestAlpnFallback.java
@@ -37,7 +37,7 @@ public class TestAlpnFallback extends Http2TestBase {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "snoop", new SnoopServlet());
-        ctx.addServletMappingDecoded("/", "snoop");
+        ctx.addServletMapping("/", "snoop");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/util/net/TestLargeClientHello.java b/test/org/apache/tomcat/util/net/TestLargeClientHello.java
index 43370f9c54..ebdab27de0 100644
--- a/test/org/apache/tomcat/util/net/TestLargeClientHello.java
+++ b/test/org/apache/tomcat/util/net/TestLargeClientHello.java
@@ -61,7 +61,7 @@ public class TestLargeClientHello extends TomcatBaseTest {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         TesterSupport.initSsl(tomcat, keystoreFile.getAbsolutePath(), false);
 
diff --git a/test/org/apache/tomcat/util/net/TestPQC.java b/test/org/apache/tomcat/util/net/TestPQC.java
index b4996a65b3..2e6bedfa55 100644
--- a/test/org/apache/tomcat/util/net/TestPQC.java
+++ b/test/org/apache/tomcat/util/net/TestPQC.java
@@ -94,7 +94,7 @@ public class TestPQC extends TomcatBaseTest {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "TesterServlet", new TesterServlet());
-        ctx.addServletMappingDecoded("/*", "TesterServlet");
+        ctx.addServletMapping("/*", "TesterServlet");
     }
 
     @Test
diff --git a/test/org/apache/tomcat/util/net/TestSSLHostConfigCipher.java b/test/org/apache/tomcat/util/net/TestSSLHostConfigCipher.java
index 75c8e90d00..90a5ee6e21 100644
--- a/test/org/apache/tomcat/util/net/TestSSLHostConfigCipher.java
+++ b/test/org/apache/tomcat/util/net/TestSSLHostConfigCipher.java
@@ -87,7 +87,7 @@ public class TestSSLHostConfigCipher extends TomcatBaseTest {
         // Simple webapp
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "TesterServlet", new TesterServlet());
-        ctxt.addServletMappingDecoded("/*", "TesterServlet");
+        ctxt.addServletMapping("/*", "TesterServlet");
     }
 
 
diff --git a/test/org/apache/tomcat/util/net/TestSSLHostConfigCompat.java b/test/org/apache/tomcat/util/net/TestSSLHostConfigCompat.java
index 86e94b59e6..1f5e51fc89 100644
--- a/test/org/apache/tomcat/util/net/TestSSLHostConfigCompat.java
+++ b/test/org/apache/tomcat/util/net/TestSSLHostConfigCompat.java
@@ -326,7 +326,7 @@ public class TestSSLHostConfigCompat extends TomcatBaseTest {
         // Simple webapp
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "TesterServlet", new TesterServlet());
-        ctxt.addServletMappingDecoded("/*", "TesterServlet");
+        ctxt.addServletMapping("/*", "TesterServlet");
     }
 
 
diff --git a/test/org/apache/tomcat/util/net/TestSSLHostConfigProtocol.java b/test/org/apache/tomcat/util/net/TestSSLHostConfigProtocol.java
index 05b14dfef3..2dc73a21c3 100644
--- a/test/org/apache/tomcat/util/net/TestSSLHostConfigProtocol.java
+++ b/test/org/apache/tomcat/util/net/TestSSLHostConfigProtocol.java
@@ -108,7 +108,7 @@ public class TestSSLHostConfigProtocol extends TomcatBaseTest {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         Tomcat tomcat = getTomcatInstance();
         tomcat.start();
@@ -129,7 +129,7 @@ public class TestSSLHostConfigProtocol extends TomcatBaseTest {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         Tomcat tomcat = getTomcatInstance();
         tomcat.start();
diff --git a/test/org/apache/tomcat/util/net/TestSsl.java b/test/org/apache/tomcat/util/net/TestSsl.java
index 6961013e60..d965b81fcd 100644
--- a/test/org/apache/tomcat/util/net/TestSsl.java
+++ b/test/org/apache/tomcat/util/net/TestSsl.java
@@ -150,7 +150,7 @@ public class TestSsl extends TomcatBaseTest {
 
         ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "post", new SimplePostServlet());
-        ctxt.addServletMappingDecoded("/post", "post");
+        ctxt.addServletMapping("/post", "post");
 
         TesterSupport.initSsl(tomcat);
         TesterSupport.configureSSLImplementation(tomcat, sslImplementationName, useOpenSSL);
@@ -183,7 +183,7 @@ public class TestSsl extends TomcatBaseTest {
 
         Context ctxt = getProgrammaticRootContext();
         Tomcat.addServlet(ctxt, "post", new SimplePostServlet());
-        ctxt.addServletMappingDecoded("/post", "post");
+        ctxt.addServletMapping("/post", "post");
         tomcat.start();
         int iterations = 8;
         CountDownLatch latch = new CountDownLatch(iterations);
@@ -460,7 +460,7 @@ public class TestSsl extends TomcatBaseTest {
         Context root = tomcat.addContext("", TEMP_DIR);
         Wrapper w = Tomcat.addServlet(root, "tester", new TesterServlet());
         w.setAsyncSupported(true);
-        root.addServletMappingDecoded("/", "tester");
+        root.addServletMapping("/", "tester");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/util/net/TestSslHandshakeFailure.java b/test/org/apache/tomcat/util/net/TestSslHandshakeFailure.java
index 06ab3b9a1d..4980e717e8 100644
--- a/test/org/apache/tomcat/util/net/TestSslHandshakeFailure.java
+++ b/test/org/apache/tomcat/util/net/TestSslHandshakeFailure.java
@@ -65,7 +65,7 @@ public class TestSslHandshakeFailure extends TomcatBaseTest {
 
         Context ctx = getProgrammaticRootContext();
         Tomcat.addServlet(ctx, "hello", new HelloWorldServlet());
-        ctx.addServletMappingDecoded("/", "hello");
+        ctx.addServletMapping("/", "hello");
 
         TesterSupport.initSsl(tomcat);
         TesterSupport.configureSSLImplementation(tomcat, sslImplementationName, useOpenSSL);
diff --git a/test/org/apache/tomcat/util/net/TesterSupport.java b/test/org/apache/tomcat/util/net/TesterSupport.java
index a3dd1abb05..86a03fa3f4 100644
--- a/test/org/apache/tomcat/util/net/TesterSupport.java
+++ b/test/org/apache/tomcat/util/net/TesterSupport.java
@@ -335,12 +335,12 @@ public final class TesterSupport {
         Context ctx = tomcat.addContext("", null);
 
         Tomcat.addServlet(ctx, "simple", new SimpleServlet());
-        ctx.addServletMappingDecoded("/unprotected", "simple");
-        ctx.addServletMappingDecoded("/protected", "simple");
+        ctx.addServletMapping("/unprotected", "simple");
+        ctx.addServletMapping("/protected", "simple");
 
         // Security constraints
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded("/protected");
+        collection.addPattern("/protected");
         SecurityConstraint sc = new SecurityConstraint();
         sc.addAuthRole(ROLE);
         sc.addCollection(collection);
diff --git a/test/org/apache/tomcat/util/net/ocsp/OcspBaseTest.java b/test/org/apache/tomcat/util/net/ocsp/OcspBaseTest.java
index f473584d57..0c0e15e06a 100644
--- a/test/org/apache/tomcat/util/net/ocsp/OcspBaseTest.java
+++ b/test/org/apache/tomcat/util/net/ocsp/OcspBaseTest.java
@@ -120,7 +120,7 @@ public class OcspBaseTest extends TomcatBaseTest {
         Context ctx = tomcat.addContext("", null);
 
         Tomcat.addServlet(ctx, "simple", new SimpleServlet());
-        ctx.addServletMappingDecoded("/simple", "simple");
+        ctx.addServletMapping("/simple", "simple");
 
         if (serverCertValid) {
             TesterSupport.initSsl(tomcat, useOpenSSLTrust);
diff --git a/test/org/apache/tomcat/util/net/ocsp/TesterOcspResponder.java b/test/org/apache/tomcat/util/net/ocsp/TesterOcspResponder.java
index 2902109cc9..67a10b5197 100644
--- a/test/org/apache/tomcat/util/net/ocsp/TesterOcspResponder.java
+++ b/test/org/apache/tomcat/util/net/ocsp/TesterOcspResponder.java
@@ -73,7 +73,7 @@ public class TesterOcspResponder {
         // No file system docBase required
         Context ctx = ocspResponder.addContext("", null);
         Wrapper w = Tomcat.addServlet(ctx, "responder", new TesterOcspResponderServlet());
-        ctx.addServletMappingDecoded("/", "responder");
+        ctx.addServletMapping("/", "responder");
         if (fixedResponse != null) {
             w.addInitParameter(TesterOcspResponderServlet.INIT_FIXED_RESPONSE, fixedResponse.toString());
         }
diff --git a/test/org/apache/tomcat/websocket/TestWebSocketFrameClient.java b/test/org/apache/tomcat/websocket/TestWebSocketFrameClient.java
index 70d554a199..d36e62e0e2 100644
--- a/test/org/apache/tomcat/websocket/TestWebSocketFrameClient.java
+++ b/test/org/apache/tomcat/websocket/TestWebSocketFrameClient.java
@@ -57,7 +57,7 @@ public class TestWebSocketFrameClient extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterFirehoseServer.ConfigInline.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -97,11 +97,11 @@ public class TestWebSocketFrameClient extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
         Context ctx2 = tomcat.addContext("/foo", null);
         ctx2.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx2, "default", new DefaultServlet());
-        ctx2.addServletMappingDecoded("/", "default");
+        ctx2.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -147,10 +147,10 @@ public class TestWebSocketFrameClient extends WebSocketBaseTest {
         Context ctx = tomcat.addContext(URI_PROTECTED, null);
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded("/");
+        collection.addPattern("/");
         String utf8User = "test";
         String utf8Pass = "123\u00A3"; // pound sign
 
@@ -185,10 +185,10 @@ public class TestWebSocketFrameClient extends WebSocketBaseTest {
         Context ctx = tomcat.addContext(URI_PROTECTED, null);
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         SecurityCollection collection = new SecurityCollection();
-        collection.addPatternDecoded("/*");
+        collection.addPattern("/*");
 
         tomcat.addUser(USER, PWD);
         tomcat.addRole(USER, ROLE);
diff --git a/test/org/apache/tomcat/websocket/TestWebSocketFrameClientSSL.java b/test/org/apache/tomcat/websocket/TestWebSocketFrameClientSSL.java
index 7a80d1a998..5cc0b1d1bd 100644
--- a/test/org/apache/tomcat/websocket/TestWebSocketFrameClientSSL.java
+++ b/test/org/apache/tomcat/websocket/TestWebSocketFrameClientSSL.java
@@ -85,7 +85,7 @@ public class TestWebSocketFrameClientSSL extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterFirehoseServer.ConfigInline.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -136,7 +136,7 @@ public class TestWebSocketFrameClientSSL extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterFirehoseServer.ConfigInline.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsPingPongMessages.java b/test/org/apache/tomcat/websocket/TestWsPingPongMessages.java
index ef907969ee..e85f833f33 100644
--- a/test/org/apache/tomcat/websocket/TestWsPingPongMessages.java
+++ b/test/org/apache/tomcat/websocket/TestWsPingPongMessages.java
@@ -50,7 +50,7 @@ public class TestWsPingPongMessages extends WebSocketBaseTest {
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsRemoteEndpoint.java b/test/org/apache/tomcat/websocket/TestWsRemoteEndpoint.java
index db9692af7a..39db87646c 100644
--- a/test/org/apache/tomcat/websocket/TestWsRemoteEndpoint.java
+++ b/test/org/apache/tomcat/websocket/TestWsRemoteEndpoint.java
@@ -95,7 +95,7 @@ public class TestWsRemoteEndpoint extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -202,7 +202,7 @@ public class TestWsRemoteEndpoint extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsSessionSuspendResume.java b/test/org/apache/tomcat/websocket/TestWsSessionSuspendResume.java
index b4f7188ddf..6c5713c0e3 100644
--- a/test/org/apache/tomcat/websocket/TestWsSessionSuspendResume.java
+++ b/test/org/apache/tomcat/websocket/TestWsSessionSuspendResume.java
@@ -55,7 +55,7 @@ public class TestWsSessionSuspendResume extends WebSocketBaseTest {
         ctx.addApplicationListener(SuspendResumeConfig.class.getName());
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -156,7 +156,7 @@ public class TestWsSessionSuspendResume extends WebSocketBaseTest {
         ctx.addApplicationListener(WebSocketFastServerTimeout.class.getName());
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsSubprotocols.java b/test/org/apache/tomcat/websocket/TestWsSubprotocols.java
index 2c413a5a12..a32d8eaa8f 100644
--- a/test/org/apache/tomcat/websocket/TestWsSubprotocols.java
+++ b/test/org/apache/tomcat/websocket/TestWsSubprotocols.java
@@ -49,7 +49,7 @@ public class TestWsSubprotocols extends WebSocketBaseTest {
         ctx.addApplicationListener(Config.class.getName());
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java
index 871bcaded2..21e332596f 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainer.java
@@ -78,7 +78,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -192,7 +192,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -366,7 +366,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -416,7 +416,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -456,7 +456,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -554,7 +554,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -636,7 +636,7 @@ public class TestWsWebSocketContainer extends WsWebSocketContainerBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerGetOpenSessions.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerGetOpenSessions.java
index 3f9f9907a1..6066224d96 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerGetOpenSessions.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerGetOpenSessions.java
@@ -172,7 +172,7 @@ public class TestWsWebSocketContainerGetOpenSessions extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSSL.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSSL.java
index 1be64765e2..7153c072d2 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSSL.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSSL.java
@@ -84,7 +84,7 @@ public class TestWsWebSocketContainerSSL extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerClient.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerClient.java
index 2f101f3473..0b3de3b074 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerClient.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerClient.java
@@ -45,7 +45,7 @@ public class TestWsWebSocketContainerSessionExpiryContainerClient extends WsWebS
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerServer.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerServer.java
index 16fbf4135e..3713e7ce39 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerServer.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpiryContainerServer.java
@@ -49,7 +49,7 @@ public class TestWsWebSocketContainerSessionExpiryContainerServer extends WsWebS
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         ctx.addApplicationListener(WebSocketServerTimeoutConfig.class.getName());
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpirySession.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpirySession.java
index e061204ef0..15671319f6 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpirySession.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerSessionExpirySession.java
@@ -45,7 +45,7 @@ public class TestWsWebSocketContainerSessionExpirySession extends WsWebSocketCon
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutClient.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutClient.java
index 86e2f23662..c06b4da612 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutClient.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutClient.java
@@ -62,7 +62,7 @@ public class TestWsWebSocketContainerTimeoutClient extends WsWebSocketContainerB
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(BlockingConfig.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutServer.java b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutServer.java
index 0a3ac0b17b..b923cc118b 100644
--- a/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutServer.java
+++ b/test/org/apache/tomcat/websocket/TestWsWebSocketContainerTimeoutServer.java
@@ -79,7 +79,7 @@ public class TestWsWebSocketContainerTimeoutServer extends WsWebSocketContainerB
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ConstantTxConfig.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/TesterConnectionLimitPerformance.java b/test/org/apache/tomcat/websocket/TesterConnectionLimitPerformance.java
index d5deb7ebf5..287c067992 100644
--- a/test/org/apache/tomcat/websocket/TesterConnectionLimitPerformance.java
+++ b/test/org/apache/tomcat/websocket/TesterConnectionLimitPerformance.java
@@ -49,7 +49,7 @@ public class TesterConnectionLimitPerformance extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         Assert.assertTrue(tomcat.getConnector().setProperty("maxConnections", "-1"));
 
diff --git a/test/org/apache/tomcat/websocket/TesterWebSocketClientProxy.java b/test/org/apache/tomcat/websocket/TesterWebSocketClientProxy.java
index 021d729059..fd8f822349 100644
--- a/test/org/apache/tomcat/websocket/TesterWebSocketClientProxy.java
+++ b/test/org/apache/tomcat/websocket/TesterWebSocketClientProxy.java
@@ -162,7 +162,7 @@ public class TesterWebSocketClientProxy extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterEchoServer.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         if (serverAuthentication) {
             // Configure Realm
@@ -171,7 +171,7 @@ public class TesterWebSocketClientProxy extends WebSocketBaseTest {
 
             // Configure security constraints
             SecurityCollection securityCollection = new SecurityCollection();
-            securityCollection.addPatternDecoded("/*");
+            securityCollection.addPattern("/*");
             SecurityConstraint securityConstraint = new SecurityConstraint();
             securityConstraint.addAuthRole(TOMCAT_ROLE);
             securityConstraint.addCollection(securityCollection);
diff --git a/test/org/apache/tomcat/websocket/WebSocketBaseTest.java b/test/org/apache/tomcat/websocket/WebSocketBaseTest.java
index 5e714ab1ec..e509f5ab29 100644
--- a/test/org/apache/tomcat/websocket/WebSocketBaseTest.java
+++ b/test/org/apache/tomcat/websocket/WebSocketBaseTest.java
@@ -35,7 +35,7 @@ public abstract class WebSocketBaseTest extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(configClass.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
         return tomcat;
diff --git a/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java b/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java
index c955e91587..6207d657cc 100644
--- a/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java
+++ b/test/org/apache/tomcat/websocket/pojo/TestEncodingDecoding.java
@@ -80,7 +80,7 @@ public class TestEncodingDecoding extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ProgrammaticServerEndpointConfig.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -126,7 +126,7 @@ public class TestEncodingDecoding extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -183,7 +183,7 @@ public class TestEncodingDecoding extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -231,7 +231,7 @@ public class TestEncodingDecoding extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -277,7 +277,7 @@ public class TestEncodingDecoding extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -763,7 +763,7 @@ public class TestEncodingDecoding extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ProgrammaticServerEndpointConfig.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/pojo/TestPojoEndpointBase.java b/test/org/apache/tomcat/websocket/pojo/TestPojoEndpointBase.java
index 0eaaacc3c6..739099df9a 100644
--- a/test/org/apache/tomcat/websocket/pojo/TestPojoEndpointBase.java
+++ b/test/org/apache/tomcat/websocket/pojo/TestPojoEndpointBase.java
@@ -56,7 +56,7 @@ public class TestPojoEndpointBase extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
@@ -86,7 +86,7 @@ public class TestPojoEndpointBase extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/pojo/TestPojoMethodMapping.java b/test/org/apache/tomcat/websocket/pojo/TestPojoMethodMapping.java
index 73a47aa303..623da81eb1 100644
--- a/test/org/apache/tomcat/websocket/pojo/TestPojoMethodMapping.java
+++ b/test/org/apache/tomcat/websocket/pojo/TestPojoMethodMapping.java
@@ -59,7 +59,7 @@ public class TestPojoMethodMapping extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(ServerConfigListener.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestAsyncMessagesPerformance.java b/test/org/apache/tomcat/websocket/server/TestAsyncMessagesPerformance.java
index d4c7d3cb64..5d594d521d 100644
--- a/test/org/apache/tomcat/websocket/server/TestAsyncMessagesPerformance.java
+++ b/test/org/apache/tomcat/websocket/server/TestAsyncMessagesPerformance.java
@@ -51,7 +51,7 @@ public class TestAsyncMessagesPerformance extends TomcatBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(TesterAsyncTiming.Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestClassLoader.java b/test/org/apache/tomcat/websocket/server/TestClassLoader.java
index 12037a6dd0..a146fad807 100644
--- a/test/org/apache/tomcat/websocket/server/TestClassLoader.java
+++ b/test/org/apache/tomcat/websocket/server/TestClassLoader.java
@@ -57,7 +57,7 @@ public class TestClassLoader extends WebSocketBaseTest {
         ctx.addApplicationListener(Config.class.getName());
 
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestCloseBug58624.java b/test/org/apache/tomcat/websocket/server/TestCloseBug58624.java
index f03d9f8c62..2fb4523af3 100644
--- a/test/org/apache/tomcat/websocket/server/TestCloseBug58624.java
+++ b/test/org/apache/tomcat/websocket/server/TestCloseBug58624.java
@@ -50,7 +50,7 @@ public class TestCloseBug58624 extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Bug58624ServerConfig.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestShutdown.java b/test/org/apache/tomcat/websocket/server/TestShutdown.java
index 5851c4bd5a..cbecf7356d 100644
--- a/test/org/apache/tomcat/websocket/server/TestShutdown.java
+++ b/test/org/apache/tomcat/websocket/server/TestShutdown.java
@@ -54,7 +54,7 @@ public class TestShutdown extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(EchoBufferedConfig.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestSlowClient.java b/test/org/apache/tomcat/websocket/server/TestSlowClient.java
index 6db82e565c..e316a0e93a 100644
--- a/test/org/apache/tomcat/websocket/server/TestSlowClient.java
+++ b/test/org/apache/tomcat/websocket/server/TestSlowClient.java
@@ -48,7 +48,7 @@ public class TestSlowClient extends WebSocketBaseTest {
         // in response to any message received.
         ctx.addApplicationListener(TesterFirehoseServer.ConfigThread.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestWsRemoteEndpointImplServerDeadlock.java b/test/org/apache/tomcat/websocket/server/TestWsRemoteEndpointImplServerDeadlock.java
index 547f141b08..2ae7f51c0c 100644
--- a/test/org/apache/tomcat/websocket/server/TestWsRemoteEndpointImplServerDeadlock.java
+++ b/test/org/apache/tomcat/websocket/server/TestWsRemoteEndpointImplServerDeadlock.java
@@ -108,7 +108,7 @@ public class TestWsRemoteEndpointImplServerDeadlock extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Bug66508Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/server/TestWsServerContainer.java b/test/org/apache/tomcat/websocket/server/TestWsServerContainer.java
index 01b78e009c..b9c558f43d 100644
--- a/test/org/apache/tomcat/websocket/server/TestWsServerContainer.java
+++ b/test/org/apache/tomcat/websocket/server/TestWsServerContainer.java
@@ -64,7 +64,7 @@ public class TestWsServerContainer extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Bug54807Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         tomcat.start();
 
@@ -79,7 +79,7 @@ public class TestWsServerContainer extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Bug54807Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/test/org/apache/tomcat/websocket/server/TesterWsRemoteEndpointImplServer.java b/test/org/apache/tomcat/websocket/server/TesterWsRemoteEndpointImplServer.java
index 8d5b73fb59..da6435211b 100644
--- a/test/org/apache/tomcat/websocket/server/TesterWsRemoteEndpointImplServer.java
+++ b/test/org/apache/tomcat/websocket/server/TesterWsRemoteEndpointImplServer.java
@@ -69,7 +69,7 @@ public class TesterWsRemoteEndpointImplServer extends WebSocketBaseTest {
         Context ctx = getProgrammaticRootContext();
         ctx.addApplicationListener(Bug58624Config.class.getName());
         Tomcat.addServlet(ctx, "default", new DefaultServlet());
-        ctx.addServletMappingDecoded("/", "default");
+        ctx.addServletMapping("/", "default");
 
         WebSocketContainer wsContainer = ContainerProvider.getWebSocketContainer();
 
diff --git a/webapps/docs/changelog.xml b/webapps/docs/changelog.xml
index ab27642d85..3363570a7b 100644
--- a/webapps/docs/changelog.xml
+++ b/webapps/docs/changelog.xml
@@ -296,6 +296,20 @@
         of particular not for attributes that implement
         <code>HttpSessionBindingListener</code>. (markt)
       </fix>
+      <fix>
+        Add a new attribute to the <code>Context</code>,
+        <code>urlPatternsProvidedInDecodedForm</code>. This attribute controls
+        whether URLs and URL patterns provided in the deployment descriptor
+        (web.xml), annotations and/or their programmatic equivalents are treated
+        as being provided in URL-encoded form (i.e. using %nn encoding) or in
+        decoded form. The Servlet specification requires that they are provided
+        in decoded form. However, Tomcat has historically treated them as if
+        they are provided in encoded form. In Tomcat 12, they will always be
+        treated as if they are provided in decoded form. This setting enables
+        migration from encoded form to decoded form on an application by
+        application basis. This attribute will be removed in Tomcat 12 where it
+        will effectively be hard-coded to <code>true</code>. (markt)
+      </fix>
     </changelog>
   </subsection>
   <subsection name="Coyote">
diff --git a/webapps/docs/config/context.xml b/webapps/docs/config/context.xml
index bb4a82d651..a9e08265c3 100644
--- a/webapps/docs/config/context.xml
+++ b/webapps/docs/config/context.xml
@@ -704,6 +704,22 @@
         penalty.</p>
       </attribute>
 
+      <attribute name="urlPatternsProvidedInDecodedForm" required="false">
+        <p>This attribute controls whether URLs and URL patterns provided in
+        the deployment descriptor (web.xml), annotations and/or their
+        programmatic equivalents are treated as being provided in URL-encoded
+        form (i.e. using %nn encoding) or in decoded form. The Servlet
+        specification requires that they are provided in decoded form. However,
+        Tomcat has historically treated them as if they are provided in encoded
+        form. In Tomcat 12, they will always be treated as if they are provided
+        in decoded form. This setting enables migration from encoded form to
+        decoded form on an application by application basis.</p>
+        <p>If not specified, the default value of <code>false</code> will be
+        used.</p>
+        <p>This attribute will be removed in Tomcat 12 where it will effectively
+        be hard-coded to <code>true</code>.</p>
+      </attribute>
+
       <attribute name="useHttpOnly" required="false">
        <p>Should the HttpOnly flag be set on session cookies to prevent client
           side script from accessing the session ID? Defaults to


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org