-
Notifications
You must be signed in to change notification settings - Fork 40.8k
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
Provide an Actuator endpoint for non-indexed session repositories #10827
Comments
@wilkinsona Thanks for reaching out. We are currently planning on adding support for finding by username for 2.1. For tracking I created spring-projects/spring-session#914 |
Thank you @rwinch. I’ll assign this one to our general 2.1 bucket for now on the assumption that our 2.1 schedules will align. We can adjust as needed if that’s not the case. |
We've repurposed this to provide an endpoint for an unindexed session repository that will allow sessions to be retrieved and deleted by ID. The ID will have to be found by some other means as listing all sessions will not be possible. |
Could you clarify whether this issue is still focused on reactive stack only or is it a general (meaning, targeting both Servlet and reactive stacks) concern now? If it's a general concern sounds like the session endpoint should probably be refactored in a way to separate functionality that depends on only Either way, I'd gladly help out with this one. Also, is there an example of actuator endpoint (outside of health, but that one's quite complex) that supports both stacks? |
It's a general concern now.
There are a few different ways this could be implemented. It should be possible for the existing
That would be great, thank you. I'll assign the issue to you.
I don't think we'll need to support both WebFlux and Servlet (MVC and Jersey) in the same endpoint. Unlike health, we won't be in a position where there's a mixture of |
Thanks for confirming this. I missed this paragraph while skimming through the docs yesterday so I was unsure whether
That's how I too saw things initially but the part I'm unsure about is whether it's acceptable for two different endpoint implementations to be annotated with |
I think it should be fine as long as only one is auto-configured at a time. One uncertainty is the configuration properties annotation processor that generates metadata for each endpoint. I'm not sure what it'll do if it encounters two endpoints with the same ID. It would be fairly quick to try it and see. |
At present, Actuator sessions endpoint is supported only on a Servlet stack and also requires an indexed session repository. With Spring Session moving to non-indexed session repositories as a default for some session stores, this means that sessions endpoint won't be available unless users opt into a (non-default) indexed session repository. This commit updates SessionEndpoint so that it is able to work with a non-indexed session repository. In such setup, it exposes operations for fetching session by id and deleting the session. Additionally, this also adds support for reactive stack by introducing ReactiveSessionEndpoint and its auto-configuration support. Closes spring-projectsgh-10827
Closing in favor of #32046. |
At present, Actuator sessions endpoint is supported only on a Servlet stack and also requires an indexed session repository. With Spring Session moving to non-indexed session repositories as a default for some session stores, this means that sessions endpoint won't be available unless users opt into a (non-default) indexed session repository. This commit updates SessionEndpoint so that it is able to work with a non-indexed session repository. In such setup, it exposes operations for fetching session by id and deleting the session. Additionally, this also adds support for reactive stack by introducing ReactiveSessionEndpoint and its auto-configuration support. Closes spring-projectsgh-10827
Spring Session's reactive support doesn't appear to have an equivalent of
FindByIndexNameSessionRepository
so the functionality of the current endpoint can't be ported over to a reactive view of the world. We'll need to figure out what to do there./cc @rwinch @vpavic
The text was updated successfully, but these errors were encountered: