HttpProxyServlet

This servlet is also provided as part of the WebLogic server distribution. It redirects a client HTTP request from the WebLogic server to a plain old HTML server such as Apache, Netscape, or IIS. The proxy server is installed by configuring it as part of an installed Web application.

This is accomplished by including the proxy servlet in the deployment descriptor for your example server. The class name for the ProxyServlet is "weblogic.tc.srvr.HttpProxyServlet." The XML clause for this might be as follows :

 <servlet> <servlet-name>ProxyServlet</servlet-name> <servlet-class>   weblogic.t3.srvr.HttpProxyServlet </servlet-class> <init-param>   <param-name>redirectURL</param-name>     <param-value>       <scheme>server:port     </param-value> </init-param> </servlet> 

In addition, you'll need to use the servlet-mapping tag to tell the ProxyServlet what sort of resources to handle:

 <servlet-mapping> <servlet-name>ProxyServlet</servlet-name> <url-pattern>*.html</url-pattern> </servlet-mapping> 

A complete example of a deployment descriptor configured to proxy HTTP requests is available on the BEA Web site at:

http://e-docs.bea.com



BEA WebLogic Server Administration Kit
BEA WebLogic Server Administration Kit (Prentice Hall PTR Advanced Web Development)
ISBN: 0130463868
EAN: 2147483647
Year: 2002
Pages: 134
Authors: Scott Hawkins

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net