From dc1ed43ac11461e51a2589de4e043a2bbeb1c2ae Mon Sep 17 00:00:00 2001 From: David Roberts Date: Fri, 6 Oct 2017 16:06:25 +0100 Subject: [PATCH] Bump monitoring cluster alert versions (elastic/x-pack-elasticsearch#2673) If the monitoring cluster alert versions are too far behind the monitoring index template versions then it causes tests in HttpExporterIT to fail. This change increases the versions for the cluster alerts to 7.0.0-alpha1 to match the increase in index template version from elastic/x-pack-elasticsearch#2614. relates elastic/x-pack-elasticsearch#2671 Original commit: elastic/x-pack-elasticsearch@b3cc3c03fe4e02bc8697cd2b164ba07f65b896ea --- .../xpack/monitoring/exporter/ClusterAlertsUtil.java | 2 +- .../monitoring/watches/elasticsearch_cluster_status.json | 2 +- .../monitoring/watches/elasticsearch_version_mismatch.json | 2 +- .../resources/monitoring/watches/kibana_version_mismatch.json | 2 +- .../resources/monitoring/watches/logstash_version_mismatch.json | 2 +- .../resources/monitoring/watches/xpack_license_expiration.json | 2 +- .../xpack/monitoring/exporter/http/HttpExporterIT.java | 2 -- 7 files changed, 6 insertions(+), 8 deletions(-) diff --git a/plugin/src/main/java/org/elasticsearch/xpack/monitoring/exporter/ClusterAlertsUtil.java b/plugin/src/main/java/org/elasticsearch/xpack/monitoring/exporter/ClusterAlertsUtil.java index 166d259abb5..db62ce63fdf 100644 --- a/plugin/src/main/java/org/elasticsearch/xpack/monitoring/exporter/ClusterAlertsUtil.java +++ b/plugin/src/main/java/org/elasticsearch/xpack/monitoring/exporter/ClusterAlertsUtil.java @@ -49,7 +49,7 @@ public class ClusterAlertsUtil { * The last time that all watches were updated. For now, all watches have been updated in the same version and should all be replaced * together. */ - public static final int LAST_UPDATED_VERSION = Version.V_6_0_0_beta1.id; + public static final int LAST_UPDATED_VERSION = Version.V_7_0_0_alpha1.id; /** * An unsorted list of Watch IDs representing resource files for Monitoring Cluster Alerts. diff --git a/plugin/src/main/resources/monitoring/watches/elasticsearch_cluster_status.json b/plugin/src/main/resources/monitoring/watches/elasticsearch_cluster_status.json index 42771647eb4..e5639c0bb1d 100644 --- a/plugin/src/main/resources/monitoring/watches/elasticsearch_cluster_status.json +++ b/plugin/src/main/resources/monitoring/watches/elasticsearch_cluster_status.json @@ -7,7 +7,7 @@ "link": "elasticsearch/indices", "severity": 2100, "type": "monitoring", - "version_created": 6000026, + "version_created": 7000001, "watch": "${monitoring.watch.id}" } }, diff --git a/plugin/src/main/resources/monitoring/watches/elasticsearch_version_mismatch.json b/plugin/src/main/resources/monitoring/watches/elasticsearch_version_mismatch.json index e787c168bfc..04328cdddb3 100644 --- a/plugin/src/main/resources/monitoring/watches/elasticsearch_version_mismatch.json +++ b/plugin/src/main/resources/monitoring/watches/elasticsearch_version_mismatch.json @@ -7,7 +7,7 @@ "link": "elasticsearch/nodes", "severity": 1000, "type": "monitoring", - "version_created": 6000026, + "version_created": 7000001, "watch": "${monitoring.watch.id}" } }, diff --git a/plugin/src/main/resources/monitoring/watches/kibana_version_mismatch.json b/plugin/src/main/resources/monitoring/watches/kibana_version_mismatch.json index 74c3319f5fe..bf2da3ffb1d 100644 --- a/plugin/src/main/resources/monitoring/watches/kibana_version_mismatch.json +++ b/plugin/src/main/resources/monitoring/watches/kibana_version_mismatch.json @@ -7,7 +7,7 @@ "link": "kibana/instances", "severity": 1000, "type": "monitoring", - "version_created": 6000026, + "version_created": 7000001, "watch": "${monitoring.watch.id}" } }, diff --git a/plugin/src/main/resources/monitoring/watches/logstash_version_mismatch.json b/plugin/src/main/resources/monitoring/watches/logstash_version_mismatch.json index 64e082bcdde..71a0cfd46bf 100644 --- a/plugin/src/main/resources/monitoring/watches/logstash_version_mismatch.json +++ b/plugin/src/main/resources/monitoring/watches/logstash_version_mismatch.json @@ -7,7 +7,7 @@ "link": "logstash/instances", "severity": 1000, "type": "monitoring", - "version_created": 6000026, + "version_created": 7000001, "watch": "${monitoring.watch.id}" } }, diff --git a/plugin/src/main/resources/monitoring/watches/xpack_license_expiration.json b/plugin/src/main/resources/monitoring/watches/xpack_license_expiration.json index 3e041d87078..2fa2a06249c 100644 --- a/plugin/src/main/resources/monitoring/watches/xpack_license_expiration.json +++ b/plugin/src/main/resources/monitoring/watches/xpack_license_expiration.json @@ -8,7 +8,7 @@ "alert_index": ".monitoring-alerts-6", "cluster_uuid": "${monitoring.watch.cluster_uuid}", "type": "monitoring", - "version_created": 6000026, + "version_created": 7000001, "watch": "${monitoring.watch.id}" } }, diff --git a/plugin/src/test/java/org/elasticsearch/xpack/monitoring/exporter/http/HttpExporterIT.java b/plugin/src/test/java/org/elasticsearch/xpack/monitoring/exporter/http/HttpExporterIT.java index d922b70d786..4abdba6d886 100644 --- a/plugin/src/test/java/org/elasticsearch/xpack/monitoring/exporter/http/HttpExporterIT.java +++ b/plugin/src/test/java/org/elasticsearch/xpack/monitoring/exporter/http/HttpExporterIT.java @@ -5,7 +5,6 @@ */ package org.elasticsearch.xpack.monitoring.exporter.http; -import org.apache.lucene.util.LuceneTestCase.AwaitsFix; import org.elasticsearch.Version; import org.elasticsearch.action.ActionListener; import org.elasticsearch.action.DocWriteRequest; @@ -73,7 +72,6 @@ import static org.hamcrest.Matchers.notNullValue; @ESIntegTestCase.ClusterScope(scope = Scope.TEST, numDataNodes = 1, numClientNodes = 0, transportClientRatio = 0.0, supportsDedicatedMasters = false) -@AwaitsFix(bugUrl = "https://github.com/elastic/x-pack-elasticsearch/issues/2671") public class HttpExporterIT extends MonitoringIntegTestCase { private final boolean templatesExistsAlready = randomBoolean();