Package org.elasticsearch.action.support
Class TransportAction<Request extends ActionRequest,Response extends ActionResponse>
java.lang.Object
org.elasticsearch.action.support.TransportAction<Request,Response>
- Direct Known Subclasses:
HandledTransportAction,TransportReplicationAction,TransportSingleShardAction
public abstract class TransportAction<Request extends ActionRequest,Response extends ActionResponse>
extends java.lang.Object
-
Field Summary
Fields Modifier and Type Field Description java.lang.StringactionNameprotected org.apache.logging.log4j.LoggerloggerDeprecated.declare your own logger.protected TaskManagertaskManager -
Constructor Summary
Constructors Modifier Constructor Description protectedTransportAction(java.lang.String actionName, ActionFilters actionFilters, TaskManager taskManager) -
Method Summary
Modifier and Type Method Description protected abstract voiddoExecute(Task task, Request request, ActionListener<Response> listener)voidexecute(Task task, Request request, ActionListener<Response> listener)Use this method when the transport action should continue to run in the context of the current taskTaskexecute(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.Taskexecute(Request request, TaskListener<Response> listener)Execute the transport action on the local node, returning theTaskused to track its execution and accepting aTaskListenerwhich listens for the completion of the action.
-
Field Details
-
actionName
public final java.lang.String actionName -
taskManager
-
logger
@Deprecated protected org.apache.logging.log4j.Logger loggerDeprecated.declare your own logger.
-
-
Constructor Details
-
TransportAction
protected TransportAction(java.lang.String actionName, ActionFilters actionFilters, TaskManager taskManager)
-
-
Method Details
-
execute
Use this method when the transport action call should result in creation of a new task associated with the call. This is a typical behavior. -
execute
Execute the transport action on the local node, returning theTaskused to track its execution and accepting aTaskListenerwhich listens for the completion of the action. -
execute
Use this method when the transport action should continue to run in the context of the current task -
doExecute
-