Class DispatcherRestEndpoint
- java.lang.Object
-
- org.apache.flink.runtime.rest.RestServerEndpoint
-
- org.apache.flink.runtime.webmonitor.WebMonitorEndpoint<DispatcherGateway>
-
- org.apache.flink.runtime.dispatcher.DispatcherRestEndpoint
-
- All Implemented Interfaces:
AutoCloseable
,LeaderContender
,RestService
,JsonArchivist
,AutoCloseableAsync
public class DispatcherRestEndpoint extends WebMonitorEndpoint<DispatcherGateway>
REST endpoint for theDispatcher
component.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class org.apache.flink.runtime.rest.RestServerEndpoint
RestServerEndpoint.RestHandlerUrlComparator
-
-
Field Summary
-
Fields inherited from class org.apache.flink.runtime.webmonitor.WebMonitorEndpoint
clusterConfiguration, executor, leaderRetriever, restConfiguration
-
Fields inherited from class org.apache.flink.runtime.rest.RestServerEndpoint
log, responseHeaders, uploadDir
-
-
Constructor Summary
Constructors Constructor Description DispatcherRestEndpoint(GatewayRetriever<DispatcherGateway> leaderRetriever, Configuration clusterConfiguration, RestHandlerConfiguration restConfiguration, GatewayRetriever<ResourceManagerGateway> resourceManagerRetriever, TransientBlobService transientBlobService, ScheduledExecutorService executor, MetricFetcher metricFetcher, LeaderElection leaderElection, ExecutionGraphCache executionGraphCache, FatalErrorHandler fatalErrorHandler)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected List<Tuple2<RestHandlerSpecification,org.apache.flink.shaded.netty4.io.netty.channel.ChannelInboundHandler>>
initializeHandlers(CompletableFuture<String> localAddressFuture)
This method is called at the beginning ofRestServerEndpoint.start()
to setup all handlers that the REST server endpoint implementation requires.protected Collection<Tuple2<RestHandlerSpecification,org.apache.flink.shaded.netty4.io.netty.channel.ChannelInboundHandler>>
initializeWebSubmissionHandlers(CompletableFuture<String> localAddressFuture)
protected CompletableFuture<Void>
shutDownInternal()
Stops this REST server endpoint.-
Methods inherited from class org.apache.flink.runtime.webmonitor.WebMonitorEndpoint
archiveJsonWithPath, createExecutorService, grantLeadership, handleError, revokeLeadership, startInternal
-
Methods inherited from class org.apache.flink.runtime.rest.RestServerEndpoint
closeAsync, getRestBaseUrl, getRestPort, getServerAddress, start
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.flink.util.AutoCloseableAsync
close
-
-
-
-
Constructor Detail
-
DispatcherRestEndpoint
public DispatcherRestEndpoint(GatewayRetriever<DispatcherGateway> leaderRetriever, Configuration clusterConfiguration, RestHandlerConfiguration restConfiguration, GatewayRetriever<ResourceManagerGateway> resourceManagerRetriever, TransientBlobService transientBlobService, ScheduledExecutorService executor, MetricFetcher metricFetcher, LeaderElection leaderElection, ExecutionGraphCache executionGraphCache, FatalErrorHandler fatalErrorHandler) throws IOException, ConfigurationException
- Throws:
IOException
ConfigurationException
-
-
Method Detail
-
initializeHandlers
protected List<Tuple2<RestHandlerSpecification,org.apache.flink.shaded.netty4.io.netty.channel.ChannelInboundHandler>> initializeHandlers(CompletableFuture<String> localAddressFuture)
Description copied from class:RestServerEndpoint
This method is called at the beginning ofRestServerEndpoint.start()
to setup all handlers that the REST server endpoint implementation requires.- Overrides:
initializeHandlers
in classWebMonitorEndpoint<DispatcherGateway>
- Parameters:
localAddressFuture
- future rest address of the RestServerEndpoint- Returns:
- Collection of AbstractRestHandler which are added to the server endpoint
-
initializeWebSubmissionHandlers
protected Collection<Tuple2<RestHandlerSpecification,org.apache.flink.shaded.netty4.io.netty.channel.ChannelInboundHandler>> initializeWebSubmissionHandlers(CompletableFuture<String> localAddressFuture)
- Overrides:
initializeWebSubmissionHandlers
in classWebMonitorEndpoint<DispatcherGateway>
-
shutDownInternal
protected CompletableFuture<Void> shutDownInternal()
Description copied from class:RestServerEndpoint
Stops this REST server endpoint.- Overrides:
shutDownInternal
in classWebMonitorEndpoint<DispatcherGateway>
- Returns:
- Future which is completed once the shut down has been finished.
-
-