public class SavepointHandlers.SavepointTriggerHandler extends AbstractAsynchronousOperationHandlers.TriggerHandler<RestfulGateway,SavepointTriggerRequestBody,SavepointTriggerMessageParameters>
log, MAPPER
leaderRetriever, localAddressFuture, logger, responseHeaders, timeout
Constructor and Description |
---|
SavepointTriggerHandler(CompletableFuture<String> localRestAddress,
GatewayRetriever<? extends RestfulGateway> leaderRetriever,
Time timeout,
Map<String,String> responseHeaders) |
Modifier and Type | Method and Description |
---|---|
protected AsynchronousJobOperationKey |
createOperationKey(HandlerRequest<SavepointTriggerRequestBody,SavepointTriggerMessageParameters> request)
Create the operation key under which the result future of the asynchronous operation will
be stored.
|
protected CompletableFuture<String> |
triggerOperation(HandlerRequest<SavepointTriggerRequestBody,SavepointTriggerMessageParameters> request,
RestfulGateway gateway)
Trigger the asynchronous operation and return its future result.
|
handleRequest
getMessageHeaders, respondToRequest
closeAsync, closeHandlerAsync, respondAsLeader
channelRead0
acceptInboundMessage, channelRead
channelActive, channelInactive, channelReadComplete, channelRegistered, channelUnregistered, channelWritabilityChanged, exceptionCaught, userEventTriggered
handlerAdded, handlerRemoved, isSharable
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
close
public SavepointTriggerHandler(CompletableFuture<String> localRestAddress, GatewayRetriever<? extends RestfulGateway> leaderRetriever, Time timeout, Map<String,String> responseHeaders)
protected CompletableFuture<String> triggerOperation(HandlerRequest<SavepointTriggerRequestBody,SavepointTriggerMessageParameters> request, RestfulGateway gateway) throws RestHandlerException
AbstractAsynchronousOperationHandlers.TriggerHandler
triggerOperation
in class AbstractAsynchronousOperationHandlers.TriggerHandler<RestfulGateway,SavepointTriggerRequestBody,SavepointTriggerMessageParameters>
request
- with which the trigger handler has been calledgateway
- to the leaderRestHandlerException
- if something went wrongprotected AsynchronousJobOperationKey createOperationKey(HandlerRequest<SavepointTriggerRequestBody,SavepointTriggerMessageParameters> request)
AbstractAsynchronousOperationHandlers.TriggerHandler
createOperationKey
in class AbstractAsynchronousOperationHandlers.TriggerHandler<RestfulGateway,SavepointTriggerRequestBody,SavepointTriggerMessageParameters>
request
- with which the trigger handler has been called.Copyright © 2014–2019 The Apache Software Foundation. All rights reserved.