org.apache.catalina.servlets
Class ManagerServlet

java.lang.Object
  |
  +--javax.servlet.GenericServlet
        |
        +--javax.servlet.http.HttpServlet
              |
              +--org.apache.catalina.servlets.ManagerServlet
All Implemented Interfaces:
ContainerServlet, java.io.Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

public final class ManagerServlet
extends javax.servlet.http.HttpServlet
implements ContainerServlet

Servlet that enables remote management of the web applications installed within the same virtual host as this web application is. Normally, this functionality will be protected by a security constraint in the web application deployment descriptor. However, this requirement can be relaxed during testing.

This servlet examines the value returned by getPathInfo() and related query parameters to determine what action is being requested. The following actions and parameters (starting after the servlet path) are supported:

Use path=/ for the ROOT context.

The syntax of the URL for a web application archive must conform to one of the following patterns to be successfully deployed:

NOTE - Attempting to reload or remove the application containing this servlet itself will not succeed. Therefore, this servlet should generally be deployed as a separate web application within the virtual host to be managed.

NOTE - For security reasons, this application will not operate when accessed via the invoker servlet. You must explicitly map this servlet with a servlet mapping, and you will always want to protect it with appropriate security constraints as well.

The following servlet initialization parameters are recognized:

Version:
$Revision: 1.5 $ $Date: 2001/05/14 00:02:32 $
Author:
Craig R. McClanahan
See Also:
Serialized Form

Constructor Summary
ManagerServlet()
           
 
Method Summary
 void destroy()
          Finalize this servlet.
 void doGet(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response)
          Process a GET request for the specified resource.
 Wrapper getWrapper()
          Return the Wrapper with which we are associated.
 void init()
          Initialize this servlet.
 void setWrapper(Wrapper wrapper)
          Set the Wrapper with which we are associated.
 
Methods inherited from class javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPost, doPut, doTrace, getLastModified, service, service
 
Methods inherited from class javax.servlet.GenericServlet
getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ManagerServlet

public ManagerServlet()
Method Detail

getWrapper

public Wrapper getWrapper()
Return the Wrapper with which we are associated.
Specified by:
getWrapper in interface ContainerServlet

setWrapper

public void setWrapper(Wrapper wrapper)
Set the Wrapper with which we are associated.
Specified by:
setWrapper in interface ContainerServlet
Parameters:
wrapper - The new wrapper

destroy

public void destroy()
Finalize this servlet.
Overrides:
destroy in class javax.servlet.GenericServlet

doGet

public void doGet(javax.servlet.http.HttpServletRequest request,
                  javax.servlet.http.HttpServletResponse response)
           throws java.io.IOException,
                  javax.servlet.ServletException
Process a GET request for the specified resource.
Overrides:
doGet in class javax.servlet.http.HttpServlet
Parameters:
request - The servlet request we are processing
response - The servlet response we are creating
Throws:
java.io.IOException - if an input/output error occurs
javax.servlet.ServletException - if a servlet-specified error occurs

init

public void init()
          throws javax.servlet.ServletException
Initialize this servlet.
Overrides:
init in class javax.servlet.GenericServlet


Copyright ? 2000 Apache Software Foundation. All Rights Reserved.