tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Nir A <>
Subject Websockets with tomcat clustering and session replication
Date Sun, 01 Dec 2013 14:33:28 GMT

Ive asked here before about how do i get a session replication over
websockets sessions.
Mark Thomas  answered me that i should try and link the httpsession with
the websocket and then i will gain the replication abilities.

So, I listended and implemented it just like in this url:

So now, I'm able to get the session for each client. and I Do get
replication! pretty nice!

Only problem is,  While i'm adding new attributes to the primary session
(in tomcat#1 for example) , the replicated sessions (in tomcat#2 for
example) does NOT contain any attribues.
The session backup is there but no attributes at all.

My POC web application has one html page with javascript web socket
send\recieve messages.

What i did notice that might shade light on whats the problem is the
following scenario:

If i press f5 on the browser, the web page is loaded and a new http
handshake is taking place. when that happens all the attributes do

Is there a way to make the attribute replicate without the need of
refreshing the page?


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message