Interface ContainerEventHandler

All Known Implementing Classes:
ModClusterService

public interface ContainerEventHandler
Defines the container events to which mod_cluster will respond. This API defines the integration point between mod_cluster and the servlet container.
Author:
Paul Ferraro
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    add(Context context)
    Indicates the deployment of a new web application which is not intending to start immediately.
    void
    init(Server server)
    Triggers the initialization of mod_cluster.
    void
    remove(Context context)
    Indicates the undeployment of the specified context.
    void
    Triggers the shutdown of mod_cluster.
    void
    start(Context context)
    Indicates the specified web application context was started.
    void
    start(Server server)
    Indicates the servlet container has been started.
    void
    status(Engine engine)
    This is a periodic event that triggers a STATUS command containing newly calculated load factor.
    void
    stop(Context context)
    Indicates the specified web application context was stopped.
    void
    stop(Server server)
    Indicates the servlet container has been stopped.
  • Method Details

    • init

      void init(Server server)
      Triggers the initialization of mod_cluster. This event should be triggered only once, after the startup of the servlet container, but before triggering the start(Server) event.
      Parameters:
      server - a server
    • shutdown

      void shutdown()
      Triggers the shutdown of mod_cluster. Closes any resources created in init(Server).
    • add

      void add(Context context)
      Indicates the deployment of a new web application which is not intending to start immediately. This will issue a STOP-APP without session draining command on the proxies. In case the application will start use start(Context).
      Parameters:
      context - the added context
    • start

      void start(Context context)
      Indicates the specified web application context was started. This event triggers an ENABLE-APP command for the specified context.
      Parameters:
      context - the started context
    • stop

      void stop(Context context)
      Indicates the specified web application context was stopped. This event triggers a STOP-APP command for the context started by start(Context).
      Parameters:
      context - the stopped context
    • remove

      void remove(Context context)
      Indicates the undeployment of the specified context. This event triggers a REMOVE-APP command for the specified context.
      Parameters:
      context - the removed context
    • status

      void status(Engine engine)
      This is a periodic event that triggers a STATUS command containing newly calculated load factor. This event also processing of newly added/discovered proxies, and reset of any proxies in error.
      Parameters:
      engine - the engine to be processed
    • start

      void start(Server server)
      Indicates the servlet container has been started. This event triggers the configuration of each servlet engine, and the addition of all web application contexts.
      Parameters:
      server - the started server
    • stop

      void stop(Server server)
      Indicates the servlet container has been stopped. This event triggers the removal of all web application contexts, and REMOVE-APP * of each engine.
      Parameters:
      server - the stopped server