-
Notifications
You must be signed in to change notification settings - Fork 150
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
Can @Loggable log exceptions at the configured log level? #149
Comments
@yegor256 please pay attention to this issue |
@jhansoty73 yes, we should fix this, thanks |
Hello @yegor256 First, thank you very much for your great work of this aspectj project, and it helped us a lot. Because I am new to aspect, I am not sure if I have found the real bug, but I hope my info could help. Hope this info will help to fix this bug, and thanks again for this great work. |
@rultor release, tag is |
@jhansoty73 @broomzhang I fixed it in a6d2021 |
@jhansoty73 @broomzhang try version 0.22.2 |
@yegor256 Thank you very much for your lightning fast fix. |
@jhansoty73 please, close this ticket. thanks! |
For a method annotated with
@Loggable(Loggable.DEBUG)
the method entry and exit messages use the configured log level, DEBUG in this case, but if the method throws an exception then a message gets logged at the ERROR level.For an exception that propagates up a call stack, this will result in multiple ERROR logs. I really want the ERROR log, if needed, be generated by the code that eventually handles the exception.
For my use case it would be ideal if the exception logging honored the log level setting in
@Loggable
. Would this fix be of interest?The text was updated successfully, but these errors were encountered: