LauncherLifecycleManager implements LifecycleManager { @Override public SlotLifecycleState restart(Deployment deployment) { updateNodeConfig(deployment); try { Command command = createCommand("restart", deployment, stopTimeout); command.execute(executor); return RUNNING; } catch (CommandFailedException e) { throw new RuntimeException("restart failed: " + e.getMessage()); } } @Inject  LauncherLifecycleManager(AgentConfig config, NodeInfo nodeInfo, HttpServerInfo httpServerInfo);  LauncherLifecycleManager(String environment,
            InetAddress internalIp,
            String externalAddress,
            InetAddress bindIp,
            Duration launcherTimeout,
            Duration launcherStopTimeout,
            URI serviceInventoryUri); @Override SlotLifecycleState status(Deployment deployment); @Override SlotLifecycleState start(Deployment deployment); @Override SlotLifecycleState restart(Deployment deployment); @Override SlotLifecycleState stop(Deployment deployment); @Override SlotLifecycleState kill(Deployment deployment); @Override void updateNodeConfig(Deployment deployment);  }
@Test public void testNodeConfigAfterRestart() throws IOException { assertEquals(manager.restart(appleDeployment), RUNNING); verifyNodeConfig(appleDeployment); }