spring-projects / spring-projects/spring-session
Session scoped beans PreDestroy not called
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.9k
- Forks
- 1.2k
- Avg merge
- 4h 27m
- Merged PRs (30d)
- 55
Description
Spring Session 2.1.1.RELEASE
This (https://spring.io/blog/2018/10/31/spring-session-bean-ga-released) mentions that it is now possible to use PreDestroy with Session scoped beans. I do not see the valueUnbound method being called when a Session is destroyed, and therefor PreDestroy is never called.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the issue with Spring Session 2.1.1.RELEASE and inspect the session-destruction path where valueUnbound should be called. Verify that destroying a session invokes the callback and consequently triggers PreDestroy for session-scoped beans; the issue is complete when this behavior is covered and works as documented.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, spring
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100