Class AdminServletContextListener

java.lang.Object
com.codahale.metrics.servlets.AdminServletContextListener
All Implemented Interfaces:
EventListener, javax.servlet.ServletContextListener

@Deprecated public abstract class AdminServletContextListener extends Object implements javax.servlet.ServletContextListener
A listener implementation which injects a MetricRegistry instance, a HealthCheckRegistry instance, and an optional ExecutorService instance into the servlet context as named attributes.
  • Constructor Details

    • AdminServletContextListener

      public AdminServletContextListener()
      Deprecated.
  • Method Details

    • getMetricRegistry

      protected abstract MetricRegistry getMetricRegistry()
      Deprecated.
      Returns the MetricRegistry to inject into the servlet context.
    • getHealthCheckRegistry

      protected abstract HealthCheckRegistry getHealthCheckRegistry()
      Deprecated.
      Returns the HealthCheckRegistry to inject into the servlet context.
    • getExecutorService

      protected ExecutorService getExecutorService()
      Deprecated.
      Returns the ExecutorService to inject into the servlet context, or null if the health checks should be run in the servlet worker thread.
    • contextInitialized

      public void contextInitialized(javax.servlet.ServletContextEvent servletContextEvent)
      Deprecated.
      Specified by:
      contextInitialized in interface javax.servlet.ServletContextListener
    • contextDestroyed

      public void contextDestroyed(javax.servlet.ServletContextEvent servletContextEvent)
      Deprecated.
      Specified by:
      contextDestroyed in interface javax.servlet.ServletContextListener