-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Add logging #159
Comments
Not sure when we'll reach MVP, lack of logs hampers authorization server in real world workloads. The same can be said about audit events, albeit to lesser extent and I'm not sure if it belongs to this ticket or new one should be created. I can try implementing at least some if it's not too early and if (as an outsider) I'm proper person for such task (this is comprehensive, I'll probably need some initial guidance that long time spring contributors already know). |
Regarding audit events, see this comment. The decision was made not to pursue that at this time as there is already a hook to hang auditing on in Spring Security. If however you are referring to something more specific, please open an issue with the details and we can discuss that. I think we'll need to do some design work before anything can be put in code, so probably best not to start anything yet. |
What about the original request to add some logging? You don't need to do a design work for that, do you? |
Unfortunately the auditing events of Spring Security are not fine-grained enough for our use case. We'd like to log details about the successful or failed Authorization requests for example. Currently, in order to achieve this, we need to override the I might have an idea, how to be able to achieve this. What about giving the possibility to provide a In case you'd want to see a working proof of concept, I'm willing to provide it! An example
An example Authentication ErrorHandler (many things are removed to keep the code focused on the goal)
|
@steinwelberg Thanks for your suggestion with I am leaning towards a pub-sub model leaving it up to the listener to do the logging or whatever it chooses to do. But we still need to decide on the design. This work won't happen until after |
We should consider using Spring Security Observability features. |
I'd like to echo the need for logging. I'm building a POC authorization server in order to assess what it's going to take to upgrade from a highly customized version of the old authorization server (assuming that it's even possible) and running into difficulties due to the lack of error logging. |
I also like to give a +1 vote for both audit and logging . one of the first thing while i making a poc for migration from old authorization server to the new code was to replacing all AuthenticationSuccessHandler and AuthenticationFailureHandler with copies and some logging to have a better idea about issues. an event driven approach for audit of success/failure with request context would be nice. |
We are considering an event driven approach for this. We'll be looking into a design soon. |
@dciarniello sounds like we are in very similar situations, we're also building a POC to assess migration from a very customised implementation based on the now deprecated spring-security-oauth2:2.5.2.RELEASE. Would definitely benefit from some logging. Would welcome any pointers to best forums where issues around this can be discussed too? We are facing a number of issues around this that it would be really useful to discuss. Thanks all |
@AlTurner-MOJ see Getting Help for some tips on that. We regularly review the spring-security tag on stackoverflow if you have focused questions. If you just need to talk it out, I'm happy to reply to a thread on gitter. |
@AlTurner-MOJ , my approach has been to attach a debugger and track down the problem but that's a PITA. I see that the timeline for the 1.0 release has been published and that this ticket is still on hold. I would suggest that logging is a MUST for the 1.0 release. Troubleshooting production issues is going to be virtually impossible without it. Is this just an authorization server issue or is it also a spring security issue? I've seen errors that look to be more properly spring security that are also not being logged. |
We need to add logging to allow for more efficient troubleshooting during error conditions.
The text was updated successfully, but these errors were encountered: