@ChannelHandler.Sharable public class RuntimeMonitorHandler extends RedirectHandler<JobManagerGateway> implements WebHandler
RequestHandler
.
This handler also deals with setting correct response MIME types and returning
proper codes, like OK, NOT_FOUND, or SERVER_ERROR.Modifier and Type | Field and Description |
---|---|
static String |
WEB_MONITOR_ADDRESS_KEY |
leaderRetriever, localAddressFuture, logger, timeout
Constructor and Description |
---|
RuntimeMonitorHandler(WebMonitorConfig cfg,
RequestHandler handler,
GatewayRetriever<JobManagerGateway> retriever,
CompletableFuture<String> localJobManagerAddressFuture,
Time timeout) |
Modifier and Type | Method and Description |
---|---|
String[] |
getPaths()
Returns an array of REST URL's under which this handler can be registered.
|
protected void |
respondAsLeader(org.apache.flink.shaded.netty4.io.netty.channel.ChannelHandlerContext ctx,
org.apache.flink.shaded.netty4.io.netty.handler.codec.http.router.Routed routed,
JobManagerGateway jobManagerGateway) |
channelRead0
acceptInboundMessage, channelRead
channelActive, channelInactive, channelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaught, userEventTriggered
handlerAdded, handlerRemoved, isSharable
public static final String WEB_MONITOR_ADDRESS_KEY
public RuntimeMonitorHandler(WebMonitorConfig cfg, RequestHandler handler, GatewayRetriever<JobManagerGateway> retriever, CompletableFuture<String> localJobManagerAddressFuture, Time timeout)
public String[] getPaths()
WebHandler
getPaths
in interface WebHandler
protected void respondAsLeader(org.apache.flink.shaded.netty4.io.netty.channel.ChannelHandlerContext ctx, org.apache.flink.shaded.netty4.io.netty.handler.codec.http.router.Routed routed, JobManagerGateway jobManagerGateway)
respondAsLeader
in class RedirectHandler<JobManagerGateway>
Copyright © 2014–2018 The Apache Software Foundation. All rights reserved.