1 Reply Latest reply: May 16, 2012 2:50 PM by Paul Ferraro RSS

HTTP Session replication fails

Mylos Kathos Novice

Hi all,

I'm testing HTTP Session replication using AS 7.1.1 and two cluster nodes on the same machine.

I've started each node using the standalone-ha.xml file:

 

standalone -c standalone-ha.xml  -Djboss.node.name=nodeA

standalone -c standalone-ha.xml -Djboss.socket.binding.port-offset=100 -Djboss.node.name=nodeB

 

now, once started I've deployed a simple Web application (tagged as <distributable /> ) which contains a Servlet that merely outputs the Session Id:

 

out.println(request.getSession().getId());

 

When running the application in two separate Browser tabs, I can see a new Session is created each time I switch from one tab to another:

Tab1:

(http-/127.0.0.1:8080-1) ZwOmxyI0noz1MuEGRX382Pz0

Tab2;

(http-/127.0.0.1:8180-1) g2AeO9JzBcG40xgXPLtYZBmP

Again Tab1:

(http-/127.0.0.1:8080-1) EleWJ7gMp+0CTA-6hvhIgRSm

Again Tab2;

(http-/127.0.0.1:8180-1) tjZArRjxeJAcYaMSHerS+Zz9

 

am I missing out something to get it working ?

Thanks a lot

Mylos