-
Change in sessions when the load is increased (8 messages)
- Posted by: Dhanunjay E
- Posted on: November 09 2006 08:51 EST
Hi All, Please help me out. I am trying to access my application with 6 browsers at a time. I found the sessions being changed. I am using Struts 1.0, J2SDK1.4.2_08, JBoss 3.8.4. How can I resolve it? If I upgrade Struts 1.0 to Struts 1.1, will it work? Shall I go by clustering in JBoss? Please provide me a solution at the earliest. Thanks in advance, Dhanunjay E.Threaded Messages (8)
- Re: Change in sessions when the load is increased by J Moyer on November 09 2006 11:37 EST
- Re: Change in sessions when the load is increased by Dhanunjay E on November 09 2006 13:38 EST
- Re: Change in sessions when the load is increased by J Moyer on November 13 2006 12:09 EST
- Re: Change in sessions when the load is increased by Dhanunjay E on November 09 2006 13:38 EST
- Re: Change in sessions when the load is increased by arijit dey on November 10 2006 01:32 EST
- Re: Change in sessions when the load is increased by Dhanunjay E on November 10 2006 01:58 EST
-
Re: Change in sessions when the load is increased by A Beloturkin on November 10 2006 02:56 EST
-
Re: Change in sessions when the load is increased by Dhanunjay E on November 10 2006 03:04 EST
- Re: Change in sessions when the load is increased by A Beloturkin on November 10 2006 03:30 EST
-
Re: Change in sessions when the load is increased by Dhanunjay E on November 10 2006 03:04 EST
-
Re: Change in sessions when the load is increased by A Beloturkin on November 10 2006 02:56 EST
- Re: Change in sessions when the load is increased by Dhanunjay E on November 10 2006 01:58 EST
-
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: J Moyer
- Posted on: November 09 2006 11:37 EST
- in response to Dhanunjay E
I am trying to access my application with 6 browsers at a time. I found the sessions being changed.
Can you clarify what you mean by "sessions being changed?" -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: Dhanunjay E
- Posted on: November 09 2006 13:38 EST
- in response to J Moyer
Hi Moyer, Actually, I tried to open 6 browsers on my machine and access the application. Logged in all the browsers with different login credentials. Then, clicked on a menu link available in my application. I observed the sessions being changed in few browsers. Session of one browser is changed to the other browser. I came to know it, when the content in one browser is displayed in other browser. Please do the needful. Thanks, Dhanunjay E -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: J Moyer
- Posted on: November 13 2006 12:09 EST
- in response to Dhanunjay E
Actually, I tried to open 6 browsers on my machine and access the application. Logged in all the browsers with different login credentials. Then, clicked on a menu link available in my application. I observed the sessions being changed in few browsers.
Assuming you're using Windows, make sure you open each browser from the start menu; this ensures each browser window has its own temporary cookies and therefore its own http session. You'll run into the problems you describe if you use ctrl-N or file-new-window to open one browser window from another. Another potential issue could be in your Struts actions. You mentioned that you just found out that Struts actions are singletons. If you have instance variables in your Struts actions, this could cause the symptom you describe. Remove any user-specific instance variables from your struts actions. Good luck!
Session of one browser is changed to the other browser. I came to know it, when the content in one browser is displayed in other browser. -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: arijit dey
- Posted on: November 10 2006 01:32 EST
- in response to Dhanunjay E
Open in internet explorer and disable cookies and tell the browser not to cache. It will worke fine. cheers, http://www.javaicillusion.blogspot.com/ -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: Dhanunjay E
- Posted on: November 10 2006 01:58 EST
- in response to arijit dey
Hi Its fine with disabling cookies. Is there any other way to resolve the problem?I came to know that all action classes in Struts1.0 are singletons by default. Is it the reason behind the sessions changing? Thanks, Dhanunjay E -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: A Beloturkin
- Posted on: November 10 2006 02:56 EST
- in response to Dhanunjay E
Hi This is expected situation. Cookies saves on your single PC and browsers can access it. If you try use your application from different PC then all be fine, and you not need disable cookie. -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: Dhanunjay E
- Posted on: November 10 2006 03:04 EST
- in response to A Beloturkin
Thanks. We didnt try in different PC's. But we got issues regarding the same session changing, resulting in exchange of data of one user to other user. It has become a security threat for us. How can we resolve it now? -
Re: Change in sessions when the load is increased[ Go to top ]
- Posted by: A Beloturkin
- Posted on: November 10 2006 03:30 EST
- in response to Dhanunjay E
You need change your Session Tracking principle. Now you are using Cookie. try look at http://www.apl.jhu.edu/~hall/java/Servlet-Tutorial/Servlet-Tutorial-Session-Tracking.html this explain how you can track session