HandledTransportAction
, TransportReplicationAction
, TransportSingleShardAction
public abstract class TransportAction<Request extends ActionRequest,Response extends ActionResponse> extends AbstractComponent
Modifier and Type | Field | Description |
---|---|---|
protected java.lang.String |
actionName |
|
protected IndexNameExpressionResolver |
indexNameExpressionResolver |
|
protected TaskManager |
taskManager |
|
protected ThreadPool |
threadPool |
deprecationLogger, logger, settings
Modifier | Constructor | Description |
---|---|---|
protected |
TransportAction(Settings settings,
java.lang.String actionName,
ThreadPool threadPool,
ActionFilters actionFilters,
IndexNameExpressionResolver indexNameExpressionResolver,
TaskManager taskManager) |
Modifier and Type | Method | Description |
---|---|---|
protected void |
doExecute(Task task,
Request request,
ActionListener<Response> listener) |
|
protected abstract void |
doExecute(Request request,
ActionListener<Response> listener) |
|
void |
execute(Task task,
Request request,
ActionListener<Response> listener) |
Use this method when the transport action should continue to run in the context of the current task
|
ActionFuture<Response> |
execute(Request request) |
|
Task |
execute(Request request,
ActionListener<Response> listener) |
Use this method when the transport action call should result in creation of a new task associated with the call.
|
Task |
execute(Request request,
TaskListener<Response> listener) |
Execute the transport action on the local node, returning the
Task used to track its execution and accepting a
TaskListener which listens for the completion of the action. |
logDeprecatedSetting, logRemovedSetting, nodeName
protected final ThreadPool threadPool
protected final java.lang.String actionName
protected final IndexNameExpressionResolver indexNameExpressionResolver
protected final TaskManager taskManager
protected TransportAction(Settings settings, java.lang.String actionName, ThreadPool threadPool, ActionFilters actionFilters, IndexNameExpressionResolver indexNameExpressionResolver, TaskManager taskManager)
public final ActionFuture<Response> execute(Request request)
public final Task execute(Request request, ActionListener<Response> listener)
public final Task execute(Request request, TaskListener<Response> listener)
Task
used to track its execution and accepting a
TaskListener
which listens for the completion of the action.public final void execute(Task task, Request request, ActionListener<Response> listener)
protected void doExecute(Task task, Request request, ActionListener<Response> listener)
protected abstract void doExecute(Request request, ActionListener<Response> listener)