protected ResourceManagerRunner[] startResourceManagers( Configuration configuration, HighAvailabilityServices haServices, HeartbeatServices heartbeatServices, MetricRegistry metricRegistry, int numResourceManagers, RpcService[] resourceManagerRpcServices) throws Exception { final ResourceManagerRunner[] resourceManagerRunners = new ResourceManagerRunner[numResourceManagers]; for (int i = 0; i < numResourceManagers; i++) { resourceManagerRunners[i] = new ResourceManagerRunner( ResourceID.generate(), FlinkResourceManager.RESOURCE_MANAGER_NAME + '_' + i, configuration, resourceManagerRpcServices[i], haServices, heartbeatServices, metricRegistry); resourceManagerRunners[i].start(); } return resourceManagerRunners; }
@Override public void onFatalError(Throwable exception) { LOG.error("Encountered fatal error.", exception); CompletableFuture<Void> shutdownFuture = closeAsync(); shutdownFuture.whenComplete( (Void ignored, Throwable throwable) -> { if (throwable != null) { LOG.error("Could not properly shut down the resource manager runner.", throwable); } }); } }
public void shutDown() throws Exception { shutDownInternally(); }
configuration, haServices, resourceManagerRunner.getResourceManageGateway(), blobServer, heartbeatServices,
if (rm != null) { try { rm.shutDown(); } catch (Throwable t) { exception = firstOrSuppressed(t, exception);
configuration, haServices, resourceManagerRunner.getResourceManageGateway(), blobServer, heartbeatServices,
protected ResourceManagerRunner startResourceManager( Configuration configuration, HighAvailabilityServices haServices, HeartbeatServices heartbeatServices, MetricRegistry metricRegistry, RpcService resourceManagerRpcService, ClusterInformation clusterInformation) throws Exception { final ResourceManagerRunner resourceManagerRunner = new ResourceManagerRunner( ResourceID.generate(), FlinkResourceManager.RESOURCE_MANAGER_NAME + '_' + UUID.randomUUID(), configuration, resourceManagerRpcService, haServices, heartbeatServices, metricRegistry, clusterInformation); resourceManagerRunner.start(); return resourceManagerRunner; }
@Override public void onFatalError(Throwable exception) { LOG.error("Encountered fatal error.", exception); CompletableFuture<Void> shutdownFuture = closeAsync(); shutdownFuture.whenComplete( (Void ignored, Throwable throwable) -> { if (throwable != null) { LOG.error("Could not properly shut down the resource manager runner.", throwable); } }); } }
configuration, haServices, resourceManagerRunner.getResourceManageGateway(), blobServer, heartbeatServices,
@Override public void onFatalError(Throwable exception) { LOG.error("Encountered fatal error.", exception); try { shutDownInternally(); } catch (Exception e) { LOG.error("Could not properly shut down the resource manager.", e); } } }
protected ResourceManagerRunner startResourceManager( Configuration configuration, HighAvailabilityServices haServices, HeartbeatServices heartbeatServices, MetricRegistry metricRegistry, RpcService resourceManagerRpcService, ClusterInformation clusterInformation, JobManagerMetricGroup jobManagerMetricGroup) throws Exception { final ResourceManagerRunner resourceManagerRunner = new ResourceManagerRunner( ResourceID.generate(), FlinkResourceManager.RESOURCE_MANAGER_NAME + '_' + UUID.randomUUID(), configuration, resourceManagerRpcService, haServices, heartbeatServices, metricRegistry, clusterInformation, jobManagerMetricGroup); resourceManagerRunner.start(); return resourceManagerRunner; }
@Override public void onFatalError(Throwable exception) { LOG.error("Encountered fatal error.", exception); CompletableFuture<Void> shutdownFuture = closeAsync(); shutdownFuture.whenComplete( (Void ignored, Throwable throwable) -> { if (throwable != null) { LOG.error("Could not properly shut down the resource manager runner.", throwable); } }); } }
protected ResourceManagerRunner startResourceManager( Configuration configuration, HighAvailabilityServices haServices, HeartbeatServices heartbeatServices, MetricRegistry metricRegistry, RpcService resourceManagerRpcService, ClusterInformation clusterInformation, JobManagerMetricGroup jobManagerMetricGroup) throws Exception { final ResourceManagerRunner resourceManagerRunner = new ResourceManagerRunner( ResourceID.generate(), FlinkResourceManager.RESOURCE_MANAGER_NAME + '_' + UUID.randomUUID(), configuration, resourceManagerRpcService, haServices, heartbeatServices, metricRegistry, clusterInformation, jobManagerMetricGroup); resourceManagerRunner.start(); return resourceManagerRunner; }
componentTerminationFutures.add(resourceManagerRunner.closeAsync()); resourceManagerRunner = null;
componentTerminationFutures.add(resourceManagerRunner.closeAsync()); resourceManagerRunner = null;
componentTerminationFutures.add(resourceManagerRunner.closeAsync()); resourceManagerRunner = null;