I use spring boot and spring cloud gateway mvc
Server 1
locahost:8082
it’s context path is /crm
Server 2
localhsot:8001
it’s context path is /acme/crm
When a call is do server 1 like
locahost:8082/crm/bff/book/1
i would like to call
localhsot:8001/acme/crm/book/1
@Bean
public RouterFunction<ServerResponse> inventoryServiceRoute() {
return route("crm_bff")
.route(RequestPredicates.path("/bff/**"), http("http://localhost:8001/acme/crm"))
.before(rewritePath("/(?<segment>.*)", "/${segment}"))
.build();
}
I get a 404
Also is there a way to display the url gateway is trying to call