Interface HooksConfig

All Superinterfaces:
Config

public interface HooksConfig extends Config
Server user hooks configuration.

Values can not be changed once the server has started.

Since:
4.4
  • Method Details

    • setStartupHook

      void setStartupHook(String className) throws ConfigException
      Sets the start up hook.

      This is the class name of a class that implements the interface com.pushtechnology.diffusion.api.publisher.ServerStartupHook. The method serverStarting will be called when the server is starting.

      If not specified, no startup hook will be called.

      Parameters:
      className - the startup hook class name
      Throws:
      ConfigException - if unable to set the property.
    • getStartupHook

      String getStartupHook()
      Gets the startup hook class name.
      Returns:
      startup hook class name or null if none specified.
    • setShutdownHook

      void setShutdownHook(String className) throws ConfigException
      Sets the value of the shutdownHook property.

      This is the class name of a class that implements the interface com.pushtechnology.diffusion.api.publisher.ServerShutdownHook. The method serverStopping will be called when the server is stopping.

      If not specified, no shutdown hook will be called.

      Parameters:
      className - the shutdown hook class name
      Throws:
      ConfigException - if unable to set the property
    • getShutdownHook

      String getShutdownHook()
      Gets the shutdown hook.
      Returns:
      shutdown hook class name or null if none specified.