Class StandaloneResourceManager
java.lang.Object
org.apache.flink.runtime.rpc.RpcEndpoint
org.apache.flink.runtime.rpc.FencedRpcEndpoint<ResourceManagerId>
org.apache.flink.runtime.resourcemanager.ResourceManager<ResourceID>
org.apache.flink.runtime.resourcemanager.StandaloneResourceManager
- All Implemented Interfaces:
AutoCloseable,BlocklistListener,ClusterPartitionManager,ResourceManagerGateway,org.apache.flink.runtime.rpc.FencedRpcGateway<ResourceManagerId>,org.apache.flink.runtime.rpc.RpcGateway,DelegationTokenManager.Listener,org.apache.flink.util.AutoCloseableAsync
A standalone implementation of the resource manager. Used when the system is started in
standalone mode (via scripts), rather than via a resource framework like YARN.
This ResourceManager doesn't acquire new resources.
-
Nested Class Summary
Nested classes/interfaces inherited from class org.apache.flink.runtime.rpc.RpcEndpoint
org.apache.flink.runtime.rpc.RpcEndpoint.MainThreadExecutor -
Field Summary
Fields inherited from class org.apache.flink.runtime.resourcemanager.ResourceManager
blocklistHandler, ioExecutor, RESOURCE_MANAGER_NAME, resourceManagerMetricGroupFields inherited from class org.apache.flink.runtime.rpc.RpcEndpoint
log, rpcServer -
Constructor Summary
ConstructorsConstructorDescriptionStandaloneResourceManager(org.apache.flink.runtime.rpc.RpcService rpcService, UUID leaderSessionId, ResourceID resourceId, HeartbeatServices heartbeatServices, DelegationTokenManager delegationTokenManager, SlotManager slotManager, ResourceManagerPartitionTrackerFactory clusterPartitionTrackerFactory, BlocklistHandler.Factory blocklistHandlerFactory, JobLeaderIdService jobLeaderIdService, ClusterInformation clusterInformation, org.apache.flink.runtime.rpc.FatalErrorHandler fatalErrorHandler, ResourceManagerMetricGroup resourceManagerMetricGroup, Duration startupPeriodTime, Duration rpcTimeout, Executor ioExecutor) -
Method Summary
Modifier and TypeMethodDescriptionGet the ready to serve future of the resource manager.protected ResourceAllocatorprotected Optional<ResourceID>getWorkerNodeIfAcceptRegistration(ResourceID resourceID) Get worker node if the worker resource is accepted.protected voidInitializes the framework specific components.protected voidinternalDeregisterApplication(ApplicationStatus finalStatus, String diagnostics) The framework specific code to deregister the application.protected voidTerminates the framework specific components.Methods inherited from class org.apache.flink.runtime.resourcemanager.ResourceManager
closeJobManagerConnection, closeTaskManagerConnection, declareRequiredResources, deregisterApplication, disconnectJobManager, disconnectTaskManager, getClusterPartitionsShuffleDescriptors, getInstanceIdByResourceId, getNumberOfRegisteredTaskManagers, getStartedFuture, getWorkerByInstanceId, heartbeatFromJobManager, heartbeatFromTaskManager, jobLeaderLostLeadership, listDataSets, notifyNewBlockedNodes, notifySlotAvailable, onFatalError, onNewTokensObtained, onStart, onStop, onWorkerRegistered, registerJobMaster, registerMetrics, registerTaskExecutor, releaseClusterPartitions, removeJob, reportClusterPartitions, requestProfiling, requestResourceOverview, requestTaskExecutorThreadInfoGateway, requestTaskManagerDetailsInfo, requestTaskManagerFileUploadByNameAndType, requestTaskManagerFileUploadByType, requestTaskManagerInfo, requestTaskManagerLogList, requestTaskManagerMetricQueryServiceAddresses, requestTaskManagerProfilingList, requestThreadDump, sendSlotReport, setFailUnfulfillableRequest, stopWorkerIfSupportedMethods inherited from class org.apache.flink.runtime.rpc.FencedRpcEndpoint
getFencingTokenMethods inherited from class org.apache.flink.runtime.rpc.RpcEndpoint
callAsync, closeAsync, getAddress, getEndpointId, getHostname, getMainThreadExecutor, getMainThreadExecutor, getRpcService, getSelfGateway, getTerminationFuture, internalCallOnStart, internalCallOnStop, isRunning, registerResource, runAsync, scheduleRunAsync, scheduleRunAsync, start, stop, unregisterResource, validateRunsInMainThreadMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.flink.util.AutoCloseableAsync
closeMethods inherited from interface org.apache.flink.runtime.rpc.FencedRpcGateway
getFencingTokenMethods inherited from interface org.apache.flink.runtime.rpc.RpcGateway
getAddress, getHostname
-
Constructor Details
-
StandaloneResourceManager
public StandaloneResourceManager(org.apache.flink.runtime.rpc.RpcService rpcService, UUID leaderSessionId, ResourceID resourceId, HeartbeatServices heartbeatServices, DelegationTokenManager delegationTokenManager, SlotManager slotManager, ResourceManagerPartitionTrackerFactory clusterPartitionTrackerFactory, BlocklistHandler.Factory blocklistHandlerFactory, JobLeaderIdService jobLeaderIdService, ClusterInformation clusterInformation, org.apache.flink.runtime.rpc.FatalErrorHandler fatalErrorHandler, ResourceManagerMetricGroup resourceManagerMetricGroup, Duration startupPeriodTime, Duration rpcTimeout, Executor ioExecutor)
-
-
Method Details
-
initialize
Description copied from class:ResourceManagerInitializes the framework specific components.- Specified by:
initializein classResourceManager<ResourceID>- Throws:
ResourceManagerException- which occurs during initialization and causes the resource manager to fail.
-
terminate
protected void terminate()Description copied from class:ResourceManagerTerminates the framework specific components.- Specified by:
terminatein classResourceManager<ResourceID>
-
internalDeregisterApplication
protected void internalDeregisterApplication(ApplicationStatus finalStatus, @Nullable String diagnostics) Description copied from class:ResourceManagerThe framework specific code to deregister the application. This should report the application's final status and shut down the resource manager cleanly.This method also needs to make sure all pending containers that are not registered yet are returned.
- Specified by:
internalDeregisterApplicationin classResourceManager<ResourceID>- Parameters:
finalStatus- The application status to report.diagnostics- A diagnostics message ornull.
-
getWorkerNodeIfAcceptRegistration
Description copied from class:ResourceManagerGet worker node if the worker resource is accepted.- Specified by:
getWorkerNodeIfAcceptRegistrationin classResourceManager<ResourceID>- Parameters:
resourceID- The worker resource id
-
getReadyToServeFuture
Description copied from class:ResourceManagerGet the ready to serve future of the resource manager.- Specified by:
getReadyToServeFuturein classResourceManager<ResourceID>- Returns:
- The ready to serve future of the resource manager, which indicated whether it is ready to serve.
-
getResourceAllocator
- Specified by:
getResourceAllocatorin classResourceManager<ResourceID>
-