Change in sessions when the load is increased

Discussions

EJB programming & troubleshooting: Change in sessions when the load is increased

  1. Change in sessions when the load is increased (8 messages)

    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.
  2. 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?"
  3. 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
  4. 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.
    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!
  5. Open in internet explorer and disable cookies and tell the browser not to cache. It will worke fine. cheers, http://www.javaicillusion.blogspot.com/
  6. 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
  7. 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.
  8. 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?
  9. 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