且构网

分享程序员开发的那些事...
且构网 - 分享程序员编程开发的那些事

Spring Session作用域bean是否保存在HttpSession中?

更新时间:2023-11-28 11:20:40

对象未真正存储在HTTP会话中.它与会话ID链接,并实际上存储在Spring上下文内部.会话监听器用于在会话关闭后清除实例.参见 SessionScope JavaDoc.

The object is not really stored in HTTP session. It is linked with session id and actually stored inside of the Spring context. A session listener is used to clean instances once session is closed. See SessionScope JavaDoc.