
|
If you were logged in you would be able to see more operations.
|
|
|
|
This seems like such an obvious problem, I feel like I'm doing something stupid.
I have a session-scoped bean in my web appcontext, and that bean declares an @Autowired HttpSession field. I would expect the current HttpSession object to be injected into the bean every time a new session-scoped instance is created. A simple test shows that the same HttpSession object is being injected into each instance of the bean.
This woul seem to be caused by the injectionMetadataCache incide AutowiredAnnotationBeanPostProcessor, unless I am very much mistaken.
To illustrate, I've attached some example files - a simple bean class, a servlet context definition, and a web.xml
What am I missing here? Is this really a bug?
|
|
Description
|
This seems like such an obvious problem, I feel like I'm doing something stupid.
I have a session-scoped bean in my web appcontext, and that bean declares an @Autowired HttpSession field. I would expect the current HttpSession object to be injected into the bean every time a new session-scoped instance is created. A simple test shows that the same HttpSession object is being injected into each instance of the bean.
This woul seem to be caused by the injectionMetadataCache incide AutowiredAnnotationBeanPostProcessor, unless I am very much mistaken.
To illustrate, I've attached some example files - a simple bean class, a servlet context definition, and a web.xml
What am I missing here? Is this really a bug? |
Show » |
|
Juergen