• Post Reply Bookmark Topic Watch Topic
  • New Topic

How to know size of a session  RSS feed

 
Sunny Kiran
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How to know size of a session ?
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There are different ways to measure them.

A session is really just a map of references to objects on the heap.
Several sessions can hold references to the same object.
Becuase of this the amount of memory your sessions consume is often smaller (in bytes) than the amount of disk space required to hold a serialized copy of the same sessions.

What exactly are you trying to do?
 
Adeel Ansari
Ranch Hand
Posts: 2874
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moreover, you can search the same forum or JSP forum with a string, "session size", and here you get many results.

cheers.
 
Bear Bibeault
Author and ninkuma
Marshal
Posts: 66149
146
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
"Sunny",

There aren't many rules that you need to worry about here on the Ranch, but one that we take very seriously regards the use of proper names. Please take a look at the JavaRanch Naming Policy and adjust your display name to match it.

In particular, your display name must be a first and a last name separated by a space character, and must not be obviously fictitious.

Thanks!
bear
Forum Bartender
 
Sunny Kiran
Greenhorn
Posts: 10
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ben...

Now i got clear idea about the size of session...

thanks bear for your advice on naming policy... i changed my display name.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Sunny,
You may want to take a look at http://javawebparts.sourceforge.net/
There is a tool in that package for measuring session size.
Since it is open source, you can explore to see how they're doing it.
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!