• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Passing Request

 
muthulingam Jayakanthan
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Help!!

Using HttpSession object is the only way to forwarding request from one servlet to another within two different web application.
Is that right, pelase verify this.
 
Nathaniel Stoddard
Ranch Hand
Posts: 1258
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Negative!

To do something like this, you 1) need to get the actual context, then 2) get the request dispatcher for that context to include/forward to the resource. Check this out (no guarantees):


Tada! Compile and be dazzled.
 
muthulingam Jayakanthan
Ranch Hand
Posts: 43
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi nethaniel,
I read one para in the Servlet 2.4 spec saying.

"Context attributes are local to the JVM in which they were created. This prevents ServletContext attributes from being a shared memory store in a distributed container. When information needs to be shared between servlets running in a distributed environment, the information should be placed into a session"

Now I got totally confused. Is this paragraph information about. please help
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic