• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Any Other Techniques other than httpSession

 
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I've been using HTTPSession objects in my applications to carry data. I would like to know if there is another technology by which we could handle this functionality. if yes, is it more efficient than using sessions?
Thanks in advance... javascript:emoticon('');
 
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Without knowing anything about your data or how it is being used, it's impossible to say anything.
 
Nitin Menon
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
Thanks for the reply.
IO don't have any data and i am not facing any situation. it is just for knowledge sake.
i just want to know if there is any way data(variables, objects, or anything that a HTTPSession can hold) can be held for use in any of the pages.
also, is the HTTPSession objects stored in the main memory?

Thanks a lot...!
 
Bear Bibeault
Sheriff
Posts: 67746
173
Mac Mac OS X IntelliJ IDE jQuery TypeScript Java iOS
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There are four scopes: page (for JSPs), request, session and application. Which to use depends upon the situation so without any specifics, impossible to answer.
 
Bartender
Posts: 6663
5
MyEclipse IDE Firefox Browser Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Bear Bibeault wrote:There are four scopes: page (for JSPs), request, session and application. Which to use depends upon the situation so without any specifics, impossible to answer.



You can use the 4 scopes that Bear mentioned. You do not have any specific requirement ?
 
Nitin Menon
Ranch Hand
Posts: 88
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
no.
Actually, one of my friends who is just into Java had asked me this doubt.
Even, i know very little.
Thanks for the information.
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

is the HTTPSession objects stored in the main memory?



Servlet containers have the option of serializing a session and storing it anywhere they want. Thats why ALL objects having a reference saved in a session should implement Serializable to avoid mysterious failures. Thats also why you should not save references to objects managed by other processes, such as DB connection pools, in sessions.

Bill

 
Ranch Hand
Posts: 5575
Eclipse IDE Windows XP Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

William Brogden wrote:Thats why ALL objects having a reference saved in a session should implement Serializable to avoid mysterious failures.



well William, is it mandatory ?
 
reply
    Bookmark Topic Watch Topic
  • New Topic