Class ServiceContainer

  • All Implemented Interfaces:
    Container

    public class ServiceContainer
    extends java.lang.Object
    implements Container
    A container for the service engine.
    • Constructor Detail

      • ServiceContainer

        public ServiceContainer()
    • Method Detail

      • init

        public void init​(java.util.List<StartupCommand> ofbizCommands,
                         java.lang.String name,
                         java.lang.String configFile)
                  throws ContainerException
        Description copied from interface: Container
        Initialize the container. This method must not block - implementations should initialize internal structures and then return.
        Specified by:
        init in interface Container
        Parameters:
        ofbizCommands - Command-line arguments.
        name - Unique name of the container's instance.
        configFile - always null but used to be the location of the global container configuration file which does not exist anymore
        Throws:
        ContainerException - If an error was encountered. Throwing this exception will halt container loading, so it should be thrown only when other containers might depend on this one.
      • start

        public boolean start()
        Description copied from interface: Container
        Start the container process. This method must not block - implementations that require thread blocking must create a separate thread and then return.
        Specified by:
        start in interface Container
        Returns:
        true if the process started.
      • stop

        public void stop()
        Description copied from interface: Container
        Stop the container process. This method must not block.
        Specified by:
        stop in interface Container
      • getName

        public java.lang.String getName()
        Description copied from interface: Container
        Return the container name.
        Specified by:
        getName in interface Container
        Returns:
        Name of the container's instance.
      • getLocalDispatcher

        public static LocalDispatcher getLocalDispatcher​(java.lang.String dispatcherName,
                                                         Delegator delegator)
      • deregister

        public static void deregister​(java.lang.String dispatcherName)
      • removeFromCache

        public static LocalDispatcher removeFromCache​(java.lang.String dispatcherName)
      • getAllDispatcherNames

        public static java.util.Set<java.lang.String> getAllDispatcherNames()