-
Notifications
You must be signed in to change notification settings - Fork 21
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
Value injector for RESTEasy #6
Comments
Is there currently any workaround to use resteasy with |
@rkorn86 there is no problem with Why don't you come explain your problem in details on the pac4j-user mailing list? It would be easier to help you :) |
To implement this, we would need to implement something like this: https://dzone.com/articles/annotations-your-way-resteasy |
If I understood correctly, it needs to be add as a singleton/resource in the resteasy runtime… |
@rkorn86 I will think of workaround tomorrow :) |
Ok, so here are some ideas to get the current profile inside a resource method: If you are running on top of a servlet container, you can very simply exploits the @GET
public void get(@Context HttpServletRequest request) {
ProfileManager manager = new ProfileManager(new J2EContext(request, null));
Optional<CommonProfile> profile = manager.get(true);
} If not, then it should be possible but a bit more complex, I will think about it in the future… |
Workaround works like a charm. Sorry, but I dont have the time/knowledge to help you currently. |
Great, I will add it to the README. No problem for the help :) |
For now value injection with
@Pac4JProfile
and@Pac4JProfileManager
only works with Jersey.The text was updated successfully, but these errors were encountered: