Depends on the servlet engine. But usually, I guess, it will hang. Anyway,
after forward() returns you shouldn't anything anymore, but simply return. This
is safe:
RequestDispatcher rd = getServletContext().getRequestDispatcher("/someuri");
if (rd != null) {
rd.forward(req, res);
return;
}
// not found
res.sendError(404);
return;
cheers,
-hendrik
- - - - - - - - - - - - - - - - - - - - - - - - - - -
tagtraum industries http://www.tagtraum.com/
jo! small&smart 2.1 servletengine
Java Server & Servlets The German servlet book
The WebApp Framework http://www.webapp.de/
Telmo S� wrote:
> Hello all.
> I have the following question:
> Supose i have a servlet that processes a client request and then is passes
> the request to another servlet or JSP using the forward directive.
> What happens to the original servlet when i forward the request to the JSP
> or servlet.
> Does it hangs until the forwarded process completes or does it runs
> separatly.
>
> Thank you.
>
> Telmo
>
> ___________________________________________________________________________
> To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
> of the message "signoff SERVLET-INTEREST".
>
> Archives: http://archives.java.sun.com/archives/servlet-interest.html
> Resources: http://java.sun.com/products/servlet/external-resources.html
> LISTSERV Help: http://www.lsoft.com/manuals/user/user.html
___________________________________________________________________________
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff SERVLET-INTEREST".
Archives: http://archives.java.sun.com/archives/servlet-interest.html
Resources: http://java.sun.com/products/servlet/external-resources.html
LISTSERV Help: http://www.lsoft.com/manuals/user/user.html