Skip to content

Map version from @HttpExchange to RequestMappingInfo#36602

Open
renatomameli wants to merge 1 commit intospring-projects:mainfrom
renatomameli:fix/httpexchange-version-mapping
Open

Map version from @HttpExchange to RequestMappingInfo#36602
renatomameli wants to merge 1 commit intospring-projects:mainfrom
renatomameli:fix/httpexchange-version-mapping

Conversation

@renatomameli
Copy link
Copy Markdown

The version attribute from @HttpExchange and its shortcut annotations such as @GetExchange was not passed to the RequestMappingInfo builder, which caused version-based routing to be silently ignored for controllers annotated with @HttpExchange.

This commit adds .version(httpExchange.version()) to the createRequestMappingInfo(HttpExchange, ...) method in both WebMvc and WebFlux RequestMappingHandlerMapping, and adds corresponding tests.

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged or decided on label Apr 5, 2026
The version attribute from @HttpExchange and its shortcut
annotations such as @GetExchange was not passed to the
RequestMappingInfo builder, which caused version-based
routing to be silently ignored for controllers annotated
with @HttpExchange.

This commit adds .version(httpExchange.version()) to the
createRequestMappingInfo(HttpExchange, ...) method in both
WebMvc and WebFlux RequestMappingHandlerMapping, and adds
corresponding tests.

Signed-off-by: Renato Mameli <renatomamel410@gmail.com>
@renatomameli renatomameli force-pushed the fix/httpexchange-version-mapping branch from e3d3272 to 9d7601b Compare April 5, 2026 19:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

status: waiting-for-triage An issue we've not yet triaged or decided on

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants