Web tier: servlets, JSP, Web frameworks: How to access web resource from a different server

  1. Hi

    Can anybody suggest, how to access a web resource on a server from a servlet which is on another web context(Different server). I don't want to use sendRedirect of the response object.
  2. There is no way to perform a forward() operation to a servlet or JSP on a different server, so that's out.

    The servlet/JSP on server A can access the servlet/JSP on server B using the same mechanism as a client: by opening an HTTP connection (using java.net.URL) and downloading its output.