I need to match a rule on pattern, rewrite the uri, and forward the resulting uri to a new host.
The following route results in a request to "/api/test/1234" to be forwarded to "http://localhost:8090/", not
"http://localhost:8090/newpath/1234" as expected.
return builder.routes() .route("test_route", r -> r.path("/api/test/**") .add(rewritePath("/api/test/","/newpath/")) .uri("http://localhost:8090") )
Is this a bug, or is the rule incorrect ? Please advice