default RoutingContext withPath(String path) {
        requireNonNull(path, "path");
        final String pathWithoutMatrixVariables;
        if (Flags.allowSemicolonInPathComponent()) {
            pathWithoutMatrixVariables = path;
        } else {
            pathWithoutMatrixVariables = removeMatrixVariables(path);
            checkArgument(pathWithoutMatrixVariables != null,
                          "path with invalid matrix variables: %s", path);
        }

        final RequestTarget oldReqTarget = requestTarget();
        final RequestTarget newReqTarget =
                DefaultRequestTarget.createWithoutValidation(
                        oldReqTarget.form(),
                        oldReqTarget.scheme(),
                        oldReqTarget.authority(),
                        oldReqTarget.host(),
                        oldReqTarget.port(),
                        pathWithoutMatrixVariables,
                        path,
                        path,
                        oldReqTarget.query(),
                        oldReqTarget.fragment());

        return new RoutingContextWrapper(this) {
            @Override
            public RequestTarget requestTarget() {
                return newReqTarget;
            }
        };
    }
(Advanced users only) Returns a wrapped {@link RoutingContext} which holds the specified {@code path}.
It is usually used to find an {@link HttpService} with a prefix-stripped path.
Note that specifying a malformed or relative path will lead to unspecified behavior.
core/src/main/java/com/linecorp/armeria/server/RoutingContext.java