Skip to content

Conversation

quaff
Copy link
Contributor

@quaff quaff commented Sep 1, 2025

See https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/context/annotation/Bean.html#destroyMethod()

This 'destroy method inference' is currently limited to detecting only public, no-arg methods named 'close' or 'shutdown'.

See https://docs.spring.io/spring-framework/docs/current/javadoc-api/org/springframework/context/annotation/Bean.html#destroyMethod()

>> This 'destroy method inference' is currently limited to detecting only public, no-arg methods named 'close' or 'shutdown'.

Signed-off-by: Yanming Zhou <[email protected]>
@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Sep 1, 2025
@philwebb
Copy link
Member

philwebb commented Sep 2, 2025

I think I prefer the explicit declarations for the "shutdown" methods, it helps make it a bit more obvious what's going on.

@philwebb philwebb added the for: team-attention An issue we'd like other members of the team to review label Sep 2, 2025
@philwebb
Copy link
Member

philwebb commented Sep 2, 2025

Looks like the consensus is to keep things as they are. Thanks anyway @quaff!

@philwebb philwebb closed this Sep 2, 2025
@philwebb philwebb added status: declined A suggestion or change that we don't feel we should currently apply and removed for: team-attention An issue we'd like other members of the team to review status: waiting-for-triage An issue we've not yet triaged labels Sep 2, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
status: declined A suggestion or change that we don't feel we should currently apply
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants