CacheManagerServlet Class

com.bea.p13n.cache.servlets
CacheManagerServlet Class

public class CacheManagerServlet

    extends HttpServlet

A servlet which can interact with the p13n caches.

This obeys the 'opeartion' query parameter:

The output will be text/xml, like:
 <caches>
   <cache>
     <name>...</name>
     <enabled>...</enabled>
     <max-entries>...</max-entries>
     <ttl>...</ttl>
     <description>...</description>
   </cache>
 </caches>
 
with the contents depending upon the opearion. 'flush' will only return <cache><name>...</name></cache> blocks for each cache flushed. 'set' will return a complete <cache></cache> block with the new values for the cache (can be used to determine if one didn't get set); if there isn't a corresponding CacheMBean for the cache, then <description> wont' be sent back. 'get' will return <cache></cache> for each cache that has an MBean entry.


Hierarchy
Object
  GenericServlet
    HttpServlet
      CacheManagerServlet
All Implemented Interfaces

Serializable, Servlet, ServletConfig

Constructor Summary

CacheManagerServlet()

 

Method Summary

public void
doCacheFlush(HttpServletRequest req, HttpServletResponse resp)
public void
doCacheGet(HttpServletRequest req, HttpServletResponse resp)
public void
doCacheSet(HttpServletRequest req, HttpServletResponse resp)
public void
doGet(HttpServletRequest req, HttpServletResponse resp)
public void
doPost(HttpServletRequest req, HttpServletResponse resp)
public static final String
xmlize(String in)
 
Methods from  javax.servlet.http.HttpServlet
doDelete, doHead, doOptions, doPut, doTrace, getLastModified, service, service
 
Methods from  javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, init, log, log, service
 
Methods from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
   
Methods from interface javax.servlet.Servlet
destroy, getServletConfig, getServletInfo, init, service
 
Methods from interface javax.servlet.ServletConfig
getInitParameter, getInitParameterNames, getServletContext, getServletName
 

Constructor Detail

CacheManagerServlet

public CacheManagerServlet()
 

Method Detail

doCacheFlush(HttpServletRequest, HttpServletResponse) Method

public void doCacheFlush(HttpServletRequest req, 
                         HttpServletResponse resp)
throws IOException

Exceptions

IOException

doCacheGet(HttpServletRequest, HttpServletResponse) Method

public void doCacheGet(HttpServletRequest req, 
                       HttpServletResponse resp)
throws IOException

Exceptions

IOException

doCacheSet(HttpServletRequest, HttpServletResponse) Method

public void doCacheSet(HttpServletRequest req, 
                       HttpServletResponse resp)
throws IOException

Exceptions

IOException

doGet(HttpServletRequest, HttpServletResponse) Method

public void doGet(HttpServletRequest req, 
                  HttpServletResponse resp)
throws IOException
Overrides
HttpServlet.doGet(HttpServletRequest, HttpServletResponse)

Exceptions

IOException

doPost(HttpServletRequest, HttpServletResponse) Method

public void doPost(HttpServletRequest req, 
                   HttpServletResponse resp)
throws IOException
Overrides
HttpServlet.doPost(HttpServletRequest, HttpServletResponse)

Exceptions

IOException

xmlize(String) Method

public static final String xmlize(String in)