diff --git a/x-pack/plugin/enrich/src/main/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyAction.java b/x-pack/plugin/enrich/src/main/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyAction.java index cc7de92cbb8c1..1e9bd8d0a3bb7 100644 --- a/x-pack/plugin/enrich/src/main/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyAction.java +++ b/x-pack/plugin/enrich/src/main/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyAction.java @@ -164,7 +164,7 @@ DiscoveryNode selectNodeForPolicyExecution(DiscoveryNodes discoNodes) { // filter out dedicated master nodes .filter(discoNode -> discoNode.getRoles().equals(Set.of(DiscoveryNodeRole.MASTER_ROLE)) == false) // Filter out nodes that don't have this action yet - .filter(discoNode -> discoNode.getVersion().onOrAfter(Version.V_8_0_0)) + .filter(discoNode -> discoNode.getVersion().onOrAfter(Version.V_7_15_0)) .toArray(DiscoveryNode[]::new); if (nodes.length == 0) { throw new IllegalStateException("no suitable node was found to perform enrich policy execution"); diff --git a/x-pack/plugin/enrich/src/test/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyActionTests.java b/x-pack/plugin/enrich/src/test/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyActionTests.java index 5ea04b5141f7e..612407d584357 100644 --- a/x-pack/plugin/enrich/src/test/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyActionTests.java +++ b/x-pack/plugin/enrich/src/test/java/org/elasticsearch/xpack/enrich/action/InternalExecutePolicyActionTests.java @@ -92,8 +92,8 @@ public void testSelectNodeForPolicyExecutionNoNodeWithIngestRole() { } public void testSelectNodeForPolicyExecutionMixedVersions() { - var node1 = newNode(randomAlphaOfLength(4), Version.V_7_16_0); - var node2 = newNode(randomAlphaOfLength(4), Version.V_7_16_0); + var node1 = newNode(randomAlphaOfLength(4), Version.V_7_14_0); + var node2 = newNode(randomAlphaOfLength(4), Version.V_7_14_0); var node3 = newNode(randomAlphaOfLength(4)); var discoNodes = DiscoveryNodes.builder() .add(node1) @@ -122,7 +122,7 @@ public void testSelectNodeForPolicyExecutionPickLocalNodeIfNotElectedMaster() { } private static DiscoveryNode newNode(String nodeId) { - return newNode(nodeId, Version.V_8_0_0); + return newNode(nodeId, Version.V_7_15_0); } private static DiscoveryNode newNode(String nodeId, Version version) { @@ -131,7 +131,7 @@ private static DiscoveryNode newNode(String nodeId, Version version) { } private static DiscoveryNode newNode(String nodeId, Set roles) { - return newNode(nodeId, roles, Version.V_8_0_0); + return newNode(nodeId, roles, Version.V_7_15_0); } private static DiscoveryNode newNode(String nodeId, Set roles, Version version) {