Remove PersistentTask#isCurrentStatus() usages

This commit is contained in:
Martijn van Groningen 2017-04-04 21:31:17 +02:00
parent 5a8512bf4e
commit fab0dc449a
No known key found for this signature in database
GPG Key ID: AB236F4FCF2AF12A
1 changed files with 4 additions and 1 deletions

View File

@ -19,7 +19,6 @@
package org.elasticsearch.persistent; package org.elasticsearch.persistent;
import org.elasticsearch.action.ActionListener; import org.elasticsearch.action.ActionListener;
import org.elasticsearch.client.Client;
import org.elasticsearch.common.Nullable; import org.elasticsearch.common.Nullable;
import org.elasticsearch.tasks.CancellableTask; import org.elasticsearch.tasks.CancellableTask;
import org.elasticsearch.tasks.Task; import org.elasticsearch.tasks.Task;
@ -116,6 +115,10 @@ public class AllocatedPersistentTask extends CancellableTask {
return state.get(); return state.get();
} }
public long getAllocationId() {
return allocationId;
}
public enum State { public enum State {
STARTED, // the task is currently running STARTED, // the task is currently running
CANCELLED, // the task is cancelled CANCELLED, // the task is cancelled