public class ResourceManagerServiceImpl extends Object implements ResourceManagerService, LeaderContender
ResourceManagerService.| 限定符和类型 | 方法和说明 |
|---|---|
CompletableFuture<Void> |
closeAsync() |
static ResourceManagerServiceImpl |
create(ResourceManagerFactory<?> resourceManagerFactory,
org.apache.flink.configuration.Configuration configuration,
ResourceID resourceId,
org.apache.flink.runtime.rpc.RpcService rpcService,
HighAvailabilityServices highAvailabilityServices,
HeartbeatServices heartbeatServices,
org.apache.flink.runtime.rpc.FatalErrorHandler fatalErrorHandler,
ClusterInformation clusterInformation,
String webInterfaceUrl,
MetricRegistry metricRegistry,
String hostname,
Executor ioExecutor) |
CompletableFuture<Void> |
deregisterApplication(ApplicationStatus applicationStatus,
String diagnostics)
Deregister the Flink application from the resource management system by signalling the
ResourceManager. |
ResourceManager<?> |
getLeaderResourceManager() |
CompletableFuture<Void> |
getTerminationFuture()
Return termination future of the service.
|
void |
grantLeadership(UUID newLeaderSessionID)
Callback method which is called by the
LeaderElectionService upon selecting this
instance as the new leader. |
void |
handleError(Exception exception)
Callback method which is called by
LeaderElectionService in case of an error in the
service thread. |
void |
revokeLeadership()
Callback method which is called by the
LeaderElectionService upon revoking the
leadership of a former leader. |
void |
start()
Start the service.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetDescriptionpublic void start()
throws Exception
ResourceManagerServicestart 在接口中 ResourceManagerServiceException - if the service cannot be startedpublic CompletableFuture<Void> getTerminationFuture()
ResourceManagerServicegetTerminationFuture 在接口中 ResourceManagerServicepublic CompletableFuture<Void> deregisterApplication(ApplicationStatus applicationStatus, @Nullable String diagnostics)
ResourceManagerServiceResourceManager.deregisterApplication 在接口中 ResourceManagerServiceapplicationStatus - to terminate the application withdiagnostics - additional information about the shut down, can be nullpublic CompletableFuture<Void> closeAsync()
closeAsync 在接口中 org.apache.flink.util.AutoCloseableAsyncpublic void grantLeadership(UUID newLeaderSessionID)
LeaderContenderLeaderElectionService upon selecting this
instance as the new leader. The method is called with the new leader session ID.grantLeadership 在接口中 LeaderContendernewLeaderSessionID - New leader session IDpublic void revokeLeadership()
LeaderContenderLeaderElectionService upon revoking the
leadership of a former leader. This might happen in case that multiple contenders have been
granted leadership.revokeLeadership 在接口中 LeaderContenderpublic void handleError(Exception exception)
LeaderContenderLeaderElectionService in case of an error in the
service thread.handleError 在接口中 LeaderContenderexception - Caught exception@VisibleForTesting @Nullable public ResourceManager<?> getLeaderResourceManager()
public static ResourceManagerServiceImpl create(ResourceManagerFactory<?> resourceManagerFactory, org.apache.flink.configuration.Configuration configuration, ResourceID resourceId, org.apache.flink.runtime.rpc.RpcService rpcService, HighAvailabilityServices highAvailabilityServices, HeartbeatServices heartbeatServices, org.apache.flink.runtime.rpc.FatalErrorHandler fatalErrorHandler, ClusterInformation clusterInformation, @Nullable String webInterfaceUrl, MetricRegistry metricRegistry, String hostname, Executor ioExecutor) throws org.apache.flink.util.ConfigurationException
org.apache.flink.util.ConfigurationExceptionCopyright © 2014–2022 The Apache Software Foundation. All rights reserved.