• 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

how I can send one httpsession for another one servlet ?

 
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi,
I need to send one httpsession of mine web service for another one servlet. When access the other servelet and I try to recoup the session, it comes as null. Somebody could help to decide this me.
Tranks
 
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
Since a HttpSession is managed by the container it is not a good idea to try holding on to a reference longer than one request/response cycle.

Why not just extract the information you need to share to a plain Java object and share that?

Are both servlets in the same web application, the same server instance, the same network, or what?


Bill
 
Marco Paradiso
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi Willian,

I need to recoup the sent information it webservice and to keep in the HTTPSession session. After this, I have I want to recoup the information of the session in the other servlet. He has some form to make this?
 
Marco Paradiso
Greenhorn
Posts: 12
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
It will be that somebody would know to help me with this?

Thanks...
reply
    Bookmark Topic Watch Topic
  • New Topic