This week's book giveaway is in the Android forum.
We're giving away four copies of Head First Android and have Dawn & David Griffiths on-line!
See this thread for details.
The moose likes Servlets and the fly likes Sharing session across servlets Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Head First Android this week in the Android forum!
JavaRanch » Java Forums » Java » Servlets
Bookmark "Sharing session across servlets" Watch "Sharing session across servlets" New topic
Author

Sharing session across servlets

Manish Hatwalne
Ranch Hand

Joined: Sep 22, 2001
Posts: 2591

Is it possible to share sessions across servlets running in two different servlet contexts? If yes, how?
TIA,
- Manish
Frank Carver
Sheriff

Joined: Jan 07, 1999
Posts: 6920
Not using the regular session mechanism. The route most people take is to persist the data which you need to share in some sort of repository reachable by servlets in both contexts (a database, JNDI repository, JavaSpace, etc.).


Read about me at frankcarver.me ~ Raspberry Alpha Omega ~ Frank's Punchbarrel Blog
Manish Hatwalne
Ranch Hand

Joined: Sep 22, 2001
Posts: 2591

Thanks!
I thought so...
- Manish
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Sharing session across servlets
 
jQuery in Action, 3rd edition