-
Notifications
You must be signed in to change notification settings - Fork 38.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
Missing destroy-method warning intentional? #28762
Comments
I think this may have been fixed, but I have not actually found the commit that changed the behavior. In any case, I don't see any logging even on TRACE with this message in it. |
Can you please try with |
We're not seeing it with any recent versions, I was just hoping to track down the actual change for "confidence". The line number should correlate to one of the MILESTONE releases so I'm still going to try and find it, but I think this can be closed. |
OK cool. I think this is (now) a duplicate of #30301. Sorry for the lack of follow-up here! |
I do see the particular log message in the code base in a different class, and it's still logged on warn, so it's possible it's still there in certain cases but just not the one we originally reported. |
The warning must be logged if something legit failed. The problem here is that it was logged for the wrong reason. |
In latest Spring 6 milestones there's a warning logged now any time a default-destroy-method is set and the method is missing from any beans (one logged per bean):
e.g.:
I don't think Spring 5 or earlier has been logging this, and before we rototilled a lot of bean files I wanted to make sure this change was intentional and going to stay. It's certainly not wrong, just somewhat inconvenient for a lot of existing files.
I did note an old (like 2009) issue filed and fixed that mentions a similar NPE and perhaps had been "fixed", suggesting maybe this is not intentional.
The text was updated successfully, but these errors were encountered: