It is possible to access a web app in a different context
Its even part of the
Servlet API
Most of the time this call will return null.
On
Tomcat you can explicitly configure a web application to allow cross context calls. (
http://tomcat.apache.org/tomcat-7.0-doc/config/context.html#Common_Attributes)
I'm not sure what other servers do (if anything)
So you can start sharing information at the level of ServletContext attributes.
In order to share session information, you would have to implement something like the HttpSessionContext used to do (with a SessionListener)
On the whole though, sharing information across two web applications on the same server is problematic.
I would take another look at this and ask if you really want to go down this path.