Align WebFlux with WebMvc for pathWithinHandlerMapping

See gh-25174
This commit is contained in:
Rossen Stoyanchev 2020-09-13 21:53:51 +01:00
parent 3295034839
commit ef10ac6b29
1 changed files with 2 additions and 0 deletions

View File

@ -366,6 +366,8 @@ public abstract class AbstractHandlerMethodMapping<T> extends AbstractHandlerMap
* @param exchange the current exchange
*/
protected void handleMatch(T mapping, HandlerMethod handlerMethod, ServerWebExchange exchange) {
String lookupPath = exchange.getRequest().getPath().pathWithinApplication().value();
exchange.getAttributes().put(PATH_WITHIN_HANDLER_MAPPING_ATTRIBUTE, lookupPath);
}
/**