-
1. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
nilindra Feb 6, 2013 8:07 AM (in response to nilindra)This is to confirm that it's happening in JBoss Enterprise Application Platform - Version 6.0.1 GA as well. Any reason?
-
2. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
jaikiran Feb 6, 2013 9:01 AM (in response to nilindra)Nilindra Fernando wrote:
Hi All,
I am facing the following strange problem with Jboss 7.1.1 AS. (I am yet to check this with EAP 6 as well)
I configured Jboss 7 with multiple instances as outline in Approach 2 of the following link.
https://community.jboss.org/wiki/MultipleInstancesOfJBossAS7OnTheSameMachine
The approach 2 assumes that you have 2 separate installations of AS7 on the same machine. i.e. separate folder structure. Is that what you have? Or are you sharing the folders, in which case you are bound to run into issues like these.
-
3. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
nilindra Feb 6, 2013 2:21 PM (in response to jaikiran)Thanks for the reply Jaikiran. I do have a seperate folder structure. i.e. jboss-as-7.1.1.Final and jboss-as-7.1.1.Final-8180 respectively. Do you mean to say in this structure the above issue should not be exist?
-
4. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
nickarls Feb 7, 2013 2:43 AM (in response to nilindra)Please check boxes ;-)
[ ] My browser supports cookies
[ ] When only a single instance is running with one deployment, refreshing browser keeps the session
[ ] When only a single instance is running with two deployments (different context roots), refreshing browser (for both context roots) keeps the session
[ ] When two instances are running with one deployment (same context root), refreshing browser creates new session (for both contexts)
[ ] When two instances are running with one deployment (different context root), refreshing browser keeps the session (for both contexts)
[ ] Both servers boot.log show separate folders for tmp/work etc.
-
5. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
nilindra Feb 10, 2013 8:36 AM (in response to nickarls)Hi Nicklas,
Sorry about the delay in getting back. Thanks for the summarization to catch all the cases ;-)
[Y] My browser supports cookies
[Y] When only a single instance is running with one deployment, refreshing browser keeps the session
[Y] When only a single instance is running with two deployments (different context roots), refreshing browser (for both context roots) keeps the session
[N] When two instances are running with one deployment (same context root), refreshing browser creates new session (for both contexts)
The Bug???
[Y] When two instances are running with one deployment (different context root), refreshing browser keeps the session (for both contexts)
[Y] Both servers boot.log show separate folders for tmp/work etc.
Attached the boot logs as well. This was tested in Jboss 7.1.1 GA
-
boot-logs.zip 3.7 KB
-
-
6. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
nickarls Feb 11, 2013 3:21 AM (in response to nilindra)Umm. There appear to be some strangeness involved here at some level.
I took my dev instance and just copy & pasted it to become another instance, cleared out the tmp/data folders and started it with a port offset. Logged in on my application on the AS1 and when I tried to do the same on AS2 it noted that I'm already logged in. I don't see how this could be the case if the session would not be common for the webapp in the two instances. It might be a cookie config thing, I'm not sure if the port is considered OOTB.
-
7. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
jaikiran Feb 11, 2013 3:43 AM (in response to nickarls)Use a custom and unique name for the jsessionid cookie for each of those instances. Here's an example on how to do it https://community.jboss.org/thread/201344?tstart=30
-
8. Re: Multiple instances (via port bindings) for same name application leads to web session mess up.
nilindra Feb 11, 2013 7:23 AM (in response to jaikiran)Thanks Jaikiran. It works now. So the same name cookie is the culprit? ;-)