From 953282ef438fb76fb3abf968eb25ea4a8161b00b Mon Sep 17 00:00:00 2001 From: Shivansh Arora Date: Tue, 29 Oct 2024 03:06:25 +0530 Subject: [PATCH] Remove assertion on Settings Signed-off-by: Shivansh Arora --- .../java/org/opensearch/upgrades/ClusterStateIT.java | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/qa/rolling-upgrade/src/test/java/org/opensearch/upgrades/ClusterStateIT.java b/qa/rolling-upgrade/src/test/java/org/opensearch/upgrades/ClusterStateIT.java index 0b3faee785420..57d9d38d6fa14 100644 --- a/qa/rolling-upgrade/src/test/java/org/opensearch/upgrades/ClusterStateIT.java +++ b/qa/rolling-upgrade/src/test/java/org/opensearch/upgrades/ClusterStateIT.java @@ -21,7 +21,6 @@ @SuppressWarnings("unchecked") public class ClusterStateIT extends AbstractRollingTestCase{ - private static final Logger logger = LogManager.getLogger(ClusterStateIT.class); private static final String templateName = "my_template"; private static final String indexName = "test_cluster_state"; private static final String componentTemplateName = "test_component_template"; @@ -69,7 +68,8 @@ public void testUpgradeWithRemotePublicationEnabled() throws Exception { verifyTemplateMetadataInClusterState(response); verifyComponentTemplateInClusterState(response); verifyComposableTemplateInClusterState(response); - verifySettingsInClusterState(); +// Settings are required to wiped after Tests, so Settings are not present after rolling upgrade starts +// verifySettingsInClusterState(); } } @@ -187,7 +187,7 @@ private static void addPersistentSettings() throws Exception { "}"; putSettings.setJsonEntity(settingsJson); - client().performRequest(putSettings); + assertOK(client().performRequest(putSettings)); } private static void addTransientSettings() throws Exception { @@ -207,7 +207,7 @@ private static void addTransientSettings() throws Exception { "}"; putSettings.setJsonEntity(settingsJson); - client().performRequest(putSettings); + assertOK(client().performRequest(putSettings)); } private static void verifyIndexInClusterState(Response clusterStateResponse) throws Exception { @@ -221,7 +221,6 @@ private static void verifyIndexInClusterState(Response clusterStateResponse) thr Map index = (Map) indices.get(indexName); assertNotNull("Index " + indexName + " should exist in cluster state", index); - logger.info(index); // Verify index settings Map settings = (Map) index.get("settings"); assertNotNull("Settings should exist in index", settings);