Package org.elasticsearch.tasks
Interface TaskAwareRequest
-
- All Known Implementing Classes:
AbstractBulkByScrollRequest,AbstractBulkIndexByScrollRequest,AcknowledgedRequest,ActionRequest,AnalyzeRequest,BaseNodeRequest,BaseNodesRequest,BaseTasksRequest,BasicReplicationRequest,BroadcastRequest,BroadcastShardRequest,BulkRequest,BulkShardRequest,BytesTransportRequest,CancelTasksRequest,ClearIndicesCacheRequest,ClearScrollRequest,CloseIndexRequest,ClusterAllocationExplainRequest,ClusterGetSettingsRequest,ClusterHealthRequest,ClusterInfoRequest,ClusterRerouteRequest,ClusterSearchShardsRequest,ClusterStateRequest,ClusterStatsRequest,ClusterUpdateSettingsRequest,CompletionPersistentTaskAction.Request,CreateIndexRequest,CreateSnapshotRequest,DeleteByQueryRequest,DeleteIndexRequest,DeleteIndexTemplateRequest,DeletePipelineRequest,DeleteRepositoryRequest,DeleteRequest,DeleteSnapshotRequest,DeleteStoredScriptRequest,ExplainRequest,FieldCapabilitiesIndexRequest,FieldCapabilitiesRequest,FlushRequest,ForceMergeRequest,GetAliasesRequest,GetFieldMappingsIndexRequest,GetFieldMappingsRequest,GetIndexRequest,GetIndexTemplatesRequest,GetMappingsRequest,GetPipelineRequest,GetRepositoriesRequest,GetRequest,GetSettingsRequest,GetSnapshotsRequest,GetStoredScriptRequest,GetTaskRequest,GlobalCheckpointSyncAction.Request,IndexRequest,IndicesAliasesRequest,IndicesExistsRequest,IndicesSegmentsRequest,IndicesShardStoresRequest,IndicesStatsRequest,InstanceShardOperationRequest,InternalScrollSearchRequest,ListTasksRequest,LivenessRequest,LocalAllocateDangledIndices.AllocateDangledRequest,MainRequest,MasterFaultDetection.MasterPingRequest,MasterNodeReadRequest,MasterNodeRequest,MembershipAction.JoinRequest,MembershipAction.LeaveRequest,MultiGetRequest,MultiGetShardRequest,MultiSearchRequest,MultiTermVectorsRequest,MultiTermVectorsShardRequest,NodeMappingRefreshAction.NodeMappingRefreshRequest,NodesFaultDetection.PingRequest,NodesHotThreadsRequest,NodesInfoRequest,NodesReloadSecureSettingsRequest,NodesStatsRequest,NodesUsageRequest,OpenIndexRequest,PendingClusterTasksRequest,PrimaryReplicaSyncer.ResyncRequest,PublishClusterStateAction.CommitClusterStateRequest,PutIndexTemplateRequest,PutMappingRequest,PutPipelineRequest,PutRepositoryRequest,PutStoredScriptRequest,QuerySearchRequest,RecoveryCleanFilesRequest,RecoveryFileChunkRequest,RecoveryFilesInfoRequest,RecoveryFinalizeRecoveryRequest,RecoveryRequest,RecoveryTranslogOperationsRequest,RecoveryWaitForClusterStateRequest,RefreshRequest,ReindexRequest,RemoteInfoRequest,RemovePersistentTaskAction.Request,ReplicatedWriteRequest,ReplicationRequest,ResizeRequest,RestoreSnapshotRequest,ResyncReplicationRequest,RetentionLeaseActions.AddRequest,RetentionLeaseActions.RemoveRequest,RetentionLeaseActions.RenewRequest,RetentionLeaseBackgroundSyncAction.Request,RetentionLeaseSyncAction.Request,RolloverRequest,SearchRequest,SearchScrollRequest,ShardFetchRequest,ShardFetchSearchRequest,ShardFlushRequest,ShardSearchTransportRequest,ShardStateAction.FailedShardEntry,ShardStateAction.StartedShardEntry,ShardUpgradeRequest,ShardValidateQueryRequest,SimulatePipelineRequest,SingleShardRequest,SnapshotShardsService.UpdateIndexShardSnapshotStatusRequest,SnapshotsStatusRequest,StartPersistentTaskAction.Request,StartRecoveryRequest,SyncedFlushRequest,SyncedFlushService.InFlightOpsRequest,SyncedFlushService.PreShardSyncedFlushRequest,SyncedFlushService.ShardSyncedFlushRequest,TermVectorsRequest,TransportBroadcastByNodeAction.NodeRequest,TransportClusterStatsAction.ClusterStatsNodeRequest,TransportNodesHotThreadsAction.NodeRequest,TransportNodesInfoAction.NodeInfoRequest,TransportNodesListGatewayMetaState.NodeRequest,TransportNodesListGatewayMetaState.Request,TransportNodesListGatewayStartedShards.NodeRequest,TransportNodesListGatewayStartedShards.Request,TransportNodesListShardStoreMetaData.NodeRequest,TransportNodesListShardStoreMetaData.Request,TransportNodesReloadSecureSettingsAction.NodeRequest,TransportNodesSnapshotsStatus.NodeRequest,TransportNodesSnapshotsStatus.Request,TransportNodesStatsAction.NodeStatsRequest,TransportNodesUsageAction.NodeUsageRequest,TransportReplicationAction.ConcreteReplicaRequest,TransportReplicationAction.ConcreteShardRequest,TransportRequest,TransportRequest.Empty,TransportVerifyShardBeforeCloseAction.ShardRequest,TypesExistsRequest,UpdateByQueryRequest,UpdatePersistentTaskStatusAction.Request,UpdateRequest,UpdateSettingsRequest,UpgradeRequest,UpgradeSettingsRequest,UpgradeStatusRequest,ValidateQueryRequest,VerifyNodeRepositoryAction.VerifyNodeRepositoryRequest,VerifyRepositoryRequest,ZenDiscovery.RejoinClusterRequest
public interface TaskAwareRequestAn interface for a request that can be used to register a task manager task
-
-
Method Summary
Modifier and Type Method Description default TaskcreateTask(long id, java.lang.String type, java.lang.String action, TaskId parentTaskId, java.util.Map<java.lang.String,java.lang.String> headers)Returns the task object that should be used to keep track of the processing of the request.default java.lang.StringgetDescription()Returns optional description of the request to be displayed by the task managerTaskIdgetParentTask()Get a reference to the task that created this request.default voidsetParentTask(java.lang.String parentTaskNode, long parentTaskId)Set a reference to task that caused this task to be run.voidsetParentTask(TaskId taskId)Set a reference to task that created this request.
-
-
-
Method Detail
-
setParentTask
default void setParentTask(java.lang.String parentTaskNode, long parentTaskId)Set a reference to task that caused this task to be run.
-
setParentTask
void setParentTask(TaskId taskId)
Set a reference to task that created this request.
-
getParentTask
TaskId getParentTask()
Get a reference to the task that created this request. Implementers should default toTaskId.EMPTY_TASK_ID, meaning "there is no parent".
-
createTask
default Task createTask(long id, java.lang.String type, java.lang.String action, TaskId parentTaskId, java.util.Map<java.lang.String,java.lang.String> headers)
Returns the task object that should be used to keep track of the processing of the request. A request can override this method and return null to avoid being tracked by the task manager.
-
getDescription
default java.lang.String getDescription()
Returns optional description of the request to be displayed by the task manager
-
-