- All Implemented Interfaces:
public abstract class LocalClusterUpdateTask extends Object implements ClusterStateTaskConfig, ClusterStateTaskExecutor<LocalClusterUpdateTask>, ClusterStateTaskListener
Used to apply state updates on nodes that are not necessarily master
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.cluster.ClusterStateTaskConfig
Method SummaryModifier and TypeMethodDescriptionBuilds a concise description of a list of tasks (to be used in logging etc.).Update the cluster state based on the current state and the given tasks.
final booleanindicates whether this executor should only run if the current node is master
timeout()The timeout for this cluster state update task configuration.no changes were made to the cluster state.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.elasticsearch.cluster.ClusterStateTaskExecutor
executepublic abstract ClusterStateTaskExecutor.ClusterTasksResult<LocalClusterUpdateTask> execute
(ClusterState currentState) throws Exception
executepublic final ClusterStateTaskExecutor.ClusterTasksResult<LocalClusterUpdateTask> execute
(ClusterState currentState, List<LocalClusterUpdateTask> tasks) throws ExceptionUpdate the cluster state based on the current state and the given tasks. Return the *same instance* if no state should be changed.
unchangedno changes were made to the cluster state. Useful to execute a runnable on the cluster state applier thread
describeTasksBuilds a concise description of a list of tasks (to be used in logging etc.). Note that the tasks given are not necessarily the same as those that will be passed to
ClusterStateTaskExecutor.execute(ClusterState, List). but are guaranteed to be a subset of them. This method can be called multiple times with different lists before execution. This allows groupd task description but the submitting source.
timeoutDescription copied from interface:
ClusterStateTaskConfigThe timeout for this cluster state update task configuration. If the cluster state update task isn't processed within this timeout, the associated
ClusterStateTaskListener.onFailure(String, Exception)is invoked.
prioritypublic Priority priority()Description copied from interface:
runOnlyOnMasterpublic final boolean runOnlyOnMaster()indicates whether this executor should only run if the current node is master