Class RestartDomainCommand

  • All Implemented Interfaces:
    AdminCommand

    @Service(name="restart-domain")
    @PerLookup
    public class RestartDomainCommand
    extends RestartServer
    implements AdminCommand
    For non-verbose mode: Stop this server, spawn a new JVM that will wait for this JVM to die. The new JVM then starts the server again. For verbose mode: We want the asadmin console itself to do the respawning -- so just return a 10 from System.exit(). This tells asadmin to restart.
    Author:
    Byron Nevins
    • Constructor Detail

      • RestartDomainCommand

        public RestartDomainCommand()
        version which will use injection
      • RestartDomainCommand

        public RestartDomainCommand​(com.sun.enterprise.module.ModulesRegistry registryIn)
        version which will not use injection
    • Method Detail

      • execute

        public void execute​(AdminCommandContext context)
        Restart of the application server : All running services are stopped. LookupManager is flushed. Client code that started us should notice the return value of 10 and restart us.
        Specified by:
        execute in interface AdminCommand
        Parameters:
        context - information