Class Start


public final class Start extends Object
OFBiz startup class.

This class implements a thread-safe state machine. The design is critical for reliable starting and stopping of the server.

The machine's current state and state changes must be encapsulated in this class. Client code may query the current state, but it may not change it.

This class uses a singleton pattern to guarantee that only one server instance is running in the VM. Client code retrieves the instance by using the getInstance() static method.

  • Method Details

    • main

      public static void main(String[] args)
      main is the entry point to execute high level OFBiz commands such as starting, stopping or checking the status of the server.
      args - The commands for OFBiz
    • getInstance

      public static Start getInstance()
      Returns the Start instance.
    • getConfig

      public Config getConfig()
      Returns the server's main configuration.
    • setConfig

      public void setConfig(Config c)
      Updates the server's main configuration.
      c - the new configuration
    • getCurrentState

      public Start.ServerState getCurrentState()
      Returns the server's current state.
    • stop

      public void stop()