Learn how to a build a cloud-first strategyRegister Now

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 459
  • Last Modified:

impact of heavy session objects

Hi
in my web application(java,jsp,struts,tomcat,oracle) the user is needed to add records as many as he wants,and later he can view these records with an option to modify these records.

Now when the user add a records i m storing these records in session object one by one and there is a final Commit button on which i perform database operations.at the time of view i fetch all records from database, put in session object and display on the screen.

If user wants to update any records he can click on any hyperlink(for each record there is hyperlink with a unique key against records in session),now this particular records is available for editing. the user update this records and old record in session is removed and this new one in added and again there is a final commit button on which i get the data rom session and perform database operation.

This application is for multiuser environment,now i want to know the impact of heavy session object in my application because there could be hundreds of records in session and any suggestions in case of  application performance degradeation.
Thanks








0
riteinfotech
Asked:
riteinfotech
1 Solution
 
Siva Prasanna KumarPrincipal Solutions ArchitectCommented:
0
 
riteinfotechAuthor Commented:
u mean heavy session doesn't effect application performance at all.....................??????????????
0
 
Siva Prasanna KumarPrincipal Solutions ArchitectCommented:
i am not 100% sure but i feel it is so because all those objetcs will be retained only till that session & later will be trashed so may have any major effect.

Thank You.
0
 
fargoCommented:
Hi,

If you store big object in every user's session and you get more hits say 1000 hits within a span of time...u can see how big it will be. If you are writing a high traffic internet app that needs to scale you will want to keep session scoped objects to a minimum.

If you are planning on getting a small  amount of traffic from a small amount of users (intranet app) than
storing objects in session can make your life very easy.  

regards,
fargo
0
 
bloodredsunCommented:
I tend to agree more with fargo. I have actually seen a web server brought to it's knees by overuse of sessions although this was dealing with 30,000 users within 20 minutes but well planned and "hygenic" use of sessions can actually improve performance dramatically as you are not repeating wasteful database connections

But also remember this; A large object to be stored in the session may be 60K so storing 1000 sessions at 60K (plus a bit for session overhead) would give you around 65 MB of session data held in the servers RAM. As many servers have up to 2/4 GB of RAM this is actually not that large so it would be feasible.

Basically it boils down to your architecture, your user base size and the hardware you'll be using.
0

Featured Post

What does it mean to be "Always On"?

Is your cloud always on? With an Always On cloud you won't have to worry about downtime for maintenance or software application code updates, ensuring that your bottom line isn't affected.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now