From 2c5e32f3d3ceee1e23a52220ab170b83db827992 Mon Sep 17 00:00:00 2001 From: Martijn van Groningen Date: Fri, 24 Feb 2017 14:32:53 +0100 Subject: [PATCH] [ML] Removed workaround that task status named writable needed to have the same name as action name. Original commit: elastic/x-pack-elasticsearch@99d9d800730be98656776060f51f69593e7101ff --- .../org/elasticsearch/xpack/ml/datafeed/DatafeedState.java | 3 +-- .../java/org/elasticsearch/xpack/ml/job/config/JobState.java | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/plugin/src/main/java/org/elasticsearch/xpack/ml/datafeed/DatafeedState.java b/plugin/src/main/java/org/elasticsearch/xpack/ml/datafeed/DatafeedState.java index d4f34683fe4..796f7a766df 100644 --- a/plugin/src/main/java/org/elasticsearch/xpack/ml/datafeed/DatafeedState.java +++ b/plugin/src/main/java/org/elasticsearch/xpack/ml/datafeed/DatafeedState.java @@ -12,7 +12,6 @@ import org.elasticsearch.common.xcontent.ConstructingObjectParser; import org.elasticsearch.common.xcontent.XContentBuilder; import org.elasticsearch.common.xcontent.XContentParser; import org.elasticsearch.tasks.Task; -import org.elasticsearch.xpack.ml.action.StartDatafeedAction; import java.io.IOException; import java.util.Locale; @@ -23,7 +22,7 @@ public enum DatafeedState implements Task.Status { STARTED, STOPPED; - public static final String NAME = StartDatafeedAction.NAME;//"DatafeedState"; + public static final String NAME = "DatafeedState"; private static final ConstructingObjectParser PARSER = new ConstructingObjectParser<>(NAME, args -> fromString((String) args[0])); diff --git a/plugin/src/main/java/org/elasticsearch/xpack/ml/job/config/JobState.java b/plugin/src/main/java/org/elasticsearch/xpack/ml/job/config/JobState.java index e48b5ca7c66..b2c179fedc7 100644 --- a/plugin/src/main/java/org/elasticsearch/xpack/ml/job/config/JobState.java +++ b/plugin/src/main/java/org/elasticsearch/xpack/ml/job/config/JobState.java @@ -12,7 +12,6 @@ import org.elasticsearch.common.xcontent.ConstructingObjectParser; import org.elasticsearch.common.xcontent.XContentBuilder; import org.elasticsearch.common.xcontent.XContentParser; import org.elasticsearch.tasks.Task; -import org.elasticsearch.xpack.ml.action.OpenJobAction; import java.io.IOException; import java.util.Arrays; @@ -29,7 +28,7 @@ public enum JobState implements Task.Status { CLOSING, CLOSED, OPENING, OPENED, FAILED; - public static final String NAME = OpenJobAction.NAME;//"JobState"; + public static final String NAME = "JobState"; private static final ConstructingObjectParser PARSER = new ConstructingObjectParser<>(NAME, args -> fromString((String) args[0]));