Class TransportInstanceSingleOperationAction<Request extends InstanceShardOperationRequest<Request>,Response extends ActionResponse>
java.lang.Object
org.elasticsearch.action.support.TransportAction<Request,Response>
org.elasticsearch.action.support.HandledTransportAction<Request,Response>
org.elasticsearch.action.support.single.instance.TransportInstanceSingleOperationAction<Request,Response>
- Direct Known Subclasses:
TransportUpdateAction
public abstract class TransportInstanceSingleOperationAction<Request extends InstanceShardOperationRequest<Request>,Response extends ActionResponse> extends HandledTransportAction<Request,Response>
-
Field Summary
Fields Modifier and Type Field Description protected ClusterService
clusterService
protected IndexNameExpressionResolver
indexNameExpressionResolver
protected ThreadPool
threadPool
protected TransportService
transportService
Fields inherited from class org.elasticsearch.action.support.TransportAction
actionName, localConnection, logger, taskManager
-
Constructor Summary
Constructors Modifier Constructor Description protected
TransportInstanceSingleOperationAction(java.lang.String actionName, ThreadPool threadPool, ClusterService clusterService, TransportService transportService, ActionFilters actionFilters, IndexNameExpressionResolver indexNameExpressionResolver, Writeable.Reader<Request> request)
-
Method Summary
Modifier and Type Method Description protected ClusterBlockException
checkGlobalBlock(ClusterState state)
protected ClusterBlockException
checkRequestBlock(ClusterState state, Request request)
protected void
doExecute(Task task, Request request, ActionListener<Response> listener)
protected abstract java.lang.String
executor(ShardId shardId)
protected abstract Response
newResponse(StreamInput in)
protected abstract void
resolveRequest(ClusterState state, Request request)
Resolves the request.protected boolean
retryOnFailure(java.lang.Exception e)
protected abstract void
shardOperation(Request request, ActionListener<Response> listener)
protected abstract ShardIterator
shards(ClusterState clusterState, Request request)
Should return an iterator with a single shard!protected TransportRequestOptions
transportOptions()
Methods inherited from class org.elasticsearch.action.support.TransportAction
execute, execute, execute
-
Field Details
-
Constructor Details
-
TransportInstanceSingleOperationAction
protected TransportInstanceSingleOperationAction(java.lang.String actionName, ThreadPool threadPool, ClusterService clusterService, TransportService transportService, ActionFilters actionFilters, IndexNameExpressionResolver indexNameExpressionResolver, Writeable.Reader<Request> request)
-
-
Method Details
-
doExecute
- Specified by:
doExecute
in classTransportAction<Request extends InstanceShardOperationRequest<Request>,Response extends ActionResponse>
-
executor
-
shardOperation
-
newResponse
- Throws:
java.io.IOException
-
checkGlobalBlock
-
checkRequestBlock
-
resolveRequest
Resolves the request. Throws an exception if the request cannot be resolved. -
retryOnFailure
protected boolean retryOnFailure(java.lang.Exception e) -
transportOptions
-
shards
Should return an iterator with a single shard!
-