-
Notifications
You must be signed in to change notification settings - Fork 472
Path segment capturing {*…}
not correctly expanded
#1793
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Can you elaborate, what |
Correct, the methodOn(...) stuff is using the webmvc URL mapping to create the URLs. /{myId}/{*path} In contrast to |
We now properly handle path segment capture variables in URI mappings. Values handed into the dummy method invocations are expanded properly and a given null results in the composite segment template variable {/…*} being rendered to advertise the ability to add further segments.
Introduced UriMapping to contain the original request mapping used on a controller method as well as a MappingVariables instance that captures all used variables of those mappings. These mappings and variables are not following URI template semantics but rather PathPattern. One example of this playing into the processing is the path segment capture syntax {*…}. This is roughly equivalent to URI template's composite path syntax {/…*}, which however looks different (as the leading slash is contained in the variable expression). While the handling of those has been added in the commit before, we now introduce the proper abstractions that cause a couple of internal deprecations and binary-incompatible changes and we only want to impose them on implementors upgrading to 2.0. Also, this allows simplifying WebHandler which has accumulated quite a bit of logic already.
I've applied a fix to You now should be able to expand values properly. Handing Backports to 1.5 and 1.4 coming in a second. Feel free to give the snapshots a try. |
Thank you! |
{*…}
not correctly expanded
I have a controller with a mapping like this
When I try to create the links for this method, I tried to use something like this:
The resulting URLs path is then
/2ffa5e8b-c141-4656-9dee-24d18a4f8ff0/{*categoryPath}
So the categoryPath is not expanded.The text was updated successfully, but these errors were encountered: