Skip to content

Conversation

@kul
Copy link

@kul kul commented May 8, 2024

With jakarta servlet APIs getPathInfo returns null. getServletPath can be used as an alternative here.

https://stackoverflow.com/a/3745971/552525

@umairk79
Copy link
Collaborator

umairk79 commented May 9, 2024

Can we add another builder method for getServletPath() instead of modifying the current one?

getPathInfo() and getServletPath() return different outputs based on the url structure and cannot be used as a direct replacement.

The new method can also be added to the non jakarta module.

@kul kul force-pushed the get_servlet_path branch from 80bc276 to ec425e4 Compare May 10, 2024 10:02
@kul
Copy link
Author

kul commented May 10, 2024

@umairk79 apologies for the confusion, I was working with spring 6 upgrade and converting a servlet to controller some time back, and somehow thought this was due to jakarta thus changed the method itself in jakarta module.

Yes, changing byPath method itself does not make sense. I have taken another attempt at it by giving the user independence on whatever way he would like to implement the bypassing and partition by consuming thw whole request context. Please have a look and let me know your thoughts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants