Skip to content
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

Handle @RequestMapping at package level [SPR-15913] #20467

Closed
spring-projects-issues opened this issue Aug 30, 2017 · 1 comment
Closed

Handle @RequestMapping at package level [SPR-15913] #20467

spring-projects-issues opened this issue Aug 30, 2017 · 1 comment
Assignees
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) status: duplicate A duplicate of another issue type: enhancement A general enhancement

Comments

@spring-projects-issues
Copy link
Collaborator

spring-projects-issues commented Aug 30, 2017

Stéphane Daviet opened SPR-15913 and commented

I would like to manage the version of my REST API in the URL, something like v1/my_resource and get all the controllers under a same package exposed under the same version path. I was seeking for an elegant way of doing this without hardly coding the version part in all the controllers (like @RequestMapping("/v1/myresource")). I would like to know if applying the @RequestMapping at the package level (in an package-info.java) is an idea that is worth trying? If yes, I would gladly try to provide a pull request.


Affects: 4.3.10

Issue Links:

@spring-projects-issues
Copy link
Collaborator Author

spring-projects-issues commented Jan 12, 2018

Rossen Stoyanchev commented

This looks like a duplicate of #19231 which was superceded by #20883. If interested please make further comments under #20883.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
in: web Issues in web modules (web, webmvc, webflux, websocket) status: duplicate A duplicate of another issue type: enhancement A general enhancement
Projects
None yet
Development

No branches or pull requests

2 participants