Tomcat Clustering - Session Replication
Web App Cart Tomcat Cluster - Session Replication
Tomcat clustering with 2 instance on 2 webserver
How it Works
To make it easy to understand how clustering works, we are gonna to take you through a series of scenarios.
In this scenario we only plan to use two tomcat instances TomcatA
and TomcatB
.
We will cover the following sequence of events:
TomcatA
starts upTomcatB
starts up (Wait the TomcatA start is complete)TomcatA
receives a request, a sessionS1
is created.TomcatA
crashesTomcatB
receives a request for sessionS1
TomcatA
starts upTomcatA
receives a request, invalidate is called on the session (S1
)TomcatB
receives a request, for a new session (S2
)TomcatA
The sessionS2
expires due to inactivity.
Manager Sticky Session
Check session manager tomcat - type primary and backup
Logs Session Replication - Listening for node worker
Session must keep with session name 48A7AF7AFFA96775AEEB6648EF82B2AC and just change name instance when crash 1 instance