@Override protected void startUp() throws Exception { service = new MasterService(masterConfig, createEnvironment("helios-master"), curatorClientFactory ); service.startAsync().awaitRunning(); }
@Override protected void shutDown() throws Exception { service.stopAsync().awaitTerminated(); }
this.zooKeeperClient = setupZookeeperClient(config); final ZooKeeperModelReporter modelReporter = new ZooKeeperModelReporter(metrics.getZooKeeperMetrics()); setUpRequestLogging(stateDirectory);
@Override protected void startUp() throws Exception { logBanner(); if (!config.getNoZooKeeperMasterRegistration()) { zkRegistrar.startAsync().awaitRunning(); } expiredJobReaper.startAsync().awaitRunning(); rollingUpdateService.startAsync().awaitRunning(); agentReaper.ifPresent(reaper -> reaper.startAsync().awaitRunning()); oldJobReaper.ifPresent(reaper -> reaper.startAsync().awaitRunning()); jobHistoryReaper.ifPresent(reaper -> reaper.startAsync().awaitRunning()); try { server.start(); } catch (Exception e) { log.error("Unable to start server, shutting down", e); server.stop(); } final ServiceRegistration serviceRegistration = ServiceRegistration.newBuilder() .endpoint("helios", "http", config.getHttpEndpoint().getPort(), config.getDomain(), config.getName()) .build(); registrar.register(serviceRegistration); }
this.zooKeeperClient = setupZookeeperClient(config); final ZooKeeperModelReporter modelReporter = new ZooKeeperModelReporter( riemannFacade, metrics.getZooKeeperMetrics()); setUpRequestLogging();
@Override protected void startUp() throws Exception { logBanner(); if (!config.getNoZooKeeperMasterRegistration()) { zkRegistrar.startAsync().awaitRunning(); } expiredJobReaper.startAsync().awaitRunning(); rollingUpdateService.startAsync().awaitRunning(); try { server.start(); } catch (Exception e) { log.error("Unable to start server, shutting down", e); server.stop(); } final ServiceRegistration serviceRegistration = ServiceRegistration.newBuilder() .endpoint("helios", "http", config.getHttpEndpoint().getPort(), config.getDomain(), config.getName()) .build(); registrar.register(serviceRegistration); }
@Override protected void startUp() throws Exception { service = new MasterService(masterConfig, createEnvironment("helios-master"), curatorClientFactory); service.startAsync().awaitRunning(); }
@Override protected void shutDown() throws Exception { service.stopAsync().awaitTerminated(); }