WebLogic集群 session复制

在实现javax.servlet.http.HttpSession的HTTP servlet中,使用HttpSession.setAttribute()方法更改会话对象中的属性。若通过setAttribute设置会话对象中的属性,则该对象及其属性将通过内存复制的方式在集群中进行复制。若使用其他方法修改会话内的对象,WebLogic Server不会复制这些更改。每次更改位于会话中的对象时,都应调用setAttribute()以跨集群更新该对象。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

Use setAttribute to Change Session State:
In an HTTP servlet that implements javax.servlet.http.HttpSession, use HttpSession.setAttribute (which replaces the deprecated putValue) to change attributes in a session object. If you set attributes in a session object with setAttribute, the object and its attributes are replicated in a cluster using in-memory replication. If you use other set methods to change objects within a session, WebLogic Server does not replicate those changes. Every time a change is made to an object that is in the session, setAttribute() should be called to update that object across the cluster.
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值