Summary: | Session listeners not called on cluster node start | ||
---|---|---|---|
Product: | Tomcat 5 | Reporter: | David Rees <drees76> |
Component: | Catalina:Cluster | Assignee: | Tomcat Developers Mailing List <dev> |
Status: | RESOLVED FIXED | ||
Severity: | regression | ||
Priority: | P2 | ||
Version: | 5.5.32 | ||
Target Milestone: | --- | ||
Hardware: | PC | ||
OS: | Linux | ||
Attachments: | Adds sessionDidActivate calss |
Description
David Rees
2010-02-09 17:43:14 UTC
Confirmed and fixed in trunk for 7.0.x I have proposed the same fix for 6.0.x and 5.5.x This has been fixed in 6.0.x and will be included in 6.0.27 onwards. Is there any chance you'll also be backporting to 5.5.x as well? Appreciate the updates... As per comment #1, it has been proposed for 5.5.x. When it gets enough votes, it will be committed. This has been fixed in 5.5.x and will be included in 5.5.30 onwards. I never got a chance to test that this was fixed until now, but testing on 5.5.32 still does not appear to work. How I'm testing: Two Linux systems running Tomcat 5.5.32 with a Cluster defined in the Host section like this: <Cluster className="org.apache.catalina.cluster.tcp.SimpleTcpCluster" receiver.sendAck="false" sender.waitForAck="false" sender.doTransmitterProcessingStats="true" sender.queueDoStats="true" sender.queueTimeWait="true"> <Valve className="org.apache.catalina.cluster.tcp.ReplicationValve" filter=".*\.gif;.*\.js;.*\.jpg;.*\.png;.*\.htm;.*\.html;.*\.css;.*\.txt;"/> <Valve className="org.apache.catalina.cluster.session.JvmRouteBinderValve" enabled="true"/> <ClusterListener className="org.apache.catalina.cluster.session.ClusterSessionListener"/> <ClusterListener className="org.apache.catalina.cluster.session.JvmRouteSessionIDBinderListener"/> </Cluster> The application has a <listener><listener-class> defined in the web.xml which implements ServletContextListener and HttpSessionListener. The HttpSessionListener methods work fine on each node. The application adds an attribute to a session which implements HttpSessionActivationListener, HttpSessionBindingListener and Serializable. The HttpSessionBindingListener methods work fine on each node. When restarting a node, the session attribute never receives any calls to sessionDidActivate when that node comes back online. Let me know if you need any more details. Created attachment 26679 [details]
Adds sessionDidActivate calss
The previous fix handled session creation/destruction but not activation
Thanks - so I guess to test this I'd have to apply the patch to Tomcat source and build it myself? 'fraid so. This has been fixed in 5.5.x and will be included in 5.5.34 onwards. |