• 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

Session between two WAR files in Websphere 4.0

 
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
According to Servlet spec 2.2/2.3 a Session must be scoped at context level in our scenario it is at a WAR file level.
I am trying to track Session in 2 servlets a/c 2 WAR files and it fails. I am using Session object.
Is there a work around to this solution apart from using Cookies?.
 
Sheriff
Posts: 4313
Android IntelliJ IDE Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The servlet 2.3 spec also requires that a WebApplication have a 1 to 1 relationship with a Servlet Context -- meaning that session can not be shared across Web Applications. (See SRV 9.2)
If you want to share information across Web Apps -- you'll need to do it on your own, through Cookies or through request parameters.
But if you need to share information between to web apps -- why not just make them a single web app?
 
Sheriff
Posts: 7001
6
Eclipse IDE Python C++ Debian Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Jessica wrote: through Cookies or through request parameters.
Or, indeed, by using any other form of communication you might use between two regular applications: a database, shared files, JNDI, JMS, etc.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic