diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index a426d86b..c3562219 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -31,7 +31,7 @@ jobs: # Explicitly set the docker-compose program path so that our build scripts in RCA can run the program # This is necessary because of the Github Actions environment and the workingDir of the Gradle environment - name: Set docker-compose path - run: DOCKER_COMPOSE_LOCATION=$(which docker-compose) + run: echo "DOCKER_COMPOSE_LOCATION=$(which docker-compose)" >> $GITHUB_ENV # Set the vm.max_map_count system property to the minimum required to run OpenSearch - name: Set vm.max_map_count run: sudo sysctl -w vm.max_map_count=262144 diff --git a/build.gradle b/build.gradle index 3c8c629d..5138ec73 100644 --- a/build.gradle +++ b/build.gradle @@ -10,7 +10,7 @@ buildscript { isSnapshot = "true" == System.getProperty("build.snapshot", "true") buildVersionQualifier = System.getProperty("build.version_qualifier", "") - default_bwc_version = System.getProperty("bwc.version", "2.12.0.0") + default_bwc_version = System.getProperty("bwc.version", "2.17.0.0") pa_bwc_version = System.getProperty("tests.bwc.version", default_bwc_version) baseName = "paBwcCluster" @@ -669,7 +669,7 @@ task integTestRemote(type: RestIntegTestTask) { testClusters { "${baseName}$i" { testDistribution = "ARCHIVE" - versions = ["2.12.0-SNAPSHOT", opensearch_version] + versions = ["2.17.0-SNAPSHOT", opensearch_version] numberOfNodes = 3 plugin(provider(new Callable() { @Override diff --git a/src/test/java/org/opensearch/performanceanalyzer/PerformanceAnalyzerPluginTests.java b/src/test/java/org/opensearch/performanceanalyzer/PerformanceAnalyzerPluginTests.java index cf7dd703..074267fb 100644 --- a/src/test/java/org/opensearch/performanceanalyzer/PerformanceAnalyzerPluginTests.java +++ b/src/test/java/org/opensearch/performanceanalyzer/PerformanceAnalyzerPluginTests.java @@ -30,7 +30,6 @@ import org.opensearch.core.indices.breaker.CircuitBreakerService; import org.opensearch.env.Environment; import org.opensearch.env.TestEnvironment; -import org.opensearch.identity.IdentityService; import org.opensearch.indices.breaker.BreakerSettings; import org.opensearch.indices.breaker.HierarchyCircuitBreakerService; import org.opensearch.performanceanalyzer.action.PerformanceAnalyzerActionFilter; @@ -64,7 +63,6 @@ public class PerformanceAnalyzerPluginTests extends OpenSearchTestCase { private CircuitBreakerService circuitBreakerService; private ClusterService clusterService; private ClusterSettings clusterSettings; - private IdentityService identityService; private MetricsRegistry metricsRegistry; @@ -90,15 +88,13 @@ public void setup() { e.printStackTrace(); } clusterService = new ClusterService(settings, clusterSettings, threadPool); - identityService = new IdentityService(Settings.EMPTY, threadPool, List.of()); restController = new RestController( Collections.emptySet(), null, nodeClient, circuitBreakerService, - usageService, - identityService); + usageService); } @After diff --git a/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerClusterConfigActionTests.java b/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerClusterConfigActionTests.java index 544d86e7..49cd687f 100644 --- a/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerClusterConfigActionTests.java +++ b/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerClusterConfigActionTests.java @@ -12,7 +12,6 @@ import java.io.IOException; import java.util.ArrayList; import java.util.Collections; -import java.util.List; import org.junit.After; import org.junit.Before; import org.junit.Test; @@ -28,7 +27,6 @@ import org.opensearch.core.rest.RestStatus; import org.opensearch.core.xcontent.NamedXContentRegistry; import org.opensearch.core.xcontent.XContentBuilder; -import org.opensearch.identity.IdentityService; import org.opensearch.indices.breaker.BreakerSettings; import org.opensearch.indices.breaker.HierarchyCircuitBreakerService; import org.opensearch.performanceanalyzer.config.PerformanceAnalyzerController; @@ -54,7 +52,6 @@ public class PerformanceAnalyzerClusterConfigActionTests { private PerformanceAnalyzerClusterSettingHandler clusterSettingHandler; private NodeStatsSettingHandler nodeStatsSettingHandler; private PerformanceAnalyzerCollectorsSettingHandler performanceAnalyzerCollectorsSettingHandler; - private IdentityService identityService; @Mock private PerformanceAnalyzerController controller; @Mock private ClusterSettingsManager clusterSettingsManager; @@ -71,15 +68,13 @@ public void init() { UsageService usageService = new UsageService(); threadPool = new TestThreadPool("test"); nodeClient = new NodeClient(Settings.EMPTY, threadPool); - identityService = new IdentityService(Settings.EMPTY, threadPool, List.of()); restController = new RestController( Collections.emptySet(), null, nodeClient, circuitBreakerService, - usageService, - identityService); + usageService); clusterSettingHandler = new PerformanceAnalyzerClusterSettingHandler(controller, clusterSettingsManager); nodeStatsSettingHandler = new NodeStatsSettingHandler(controller, clusterSettingsManager); diff --git a/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerConfigActionTests.java b/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerConfigActionTests.java index c8dbec4e..80b6b3b8 100644 --- a/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerConfigActionTests.java +++ b/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerConfigActionTests.java @@ -12,7 +12,6 @@ import java.io.IOException; import java.util.ArrayList; import java.util.Collections; -import java.util.List; import org.junit.After; import org.junit.Before; import org.junit.Test; @@ -29,7 +28,6 @@ import org.opensearch.core.rest.RestStatus; import org.opensearch.core.xcontent.NamedXContentRegistry; import org.opensearch.core.xcontent.XContentBuilder; -import org.opensearch.identity.IdentityService; import org.opensearch.indices.breaker.BreakerSettings; import org.opensearch.indices.breaker.HierarchyCircuitBreakerService; import org.opensearch.performanceanalyzer.config.PerformanceAnalyzerController; @@ -48,7 +46,6 @@ public class PerformanceAnalyzerConfigActionTests { private NodeClient nodeClient; private CircuitBreakerService circuitBreakerService; private ClusterSettings clusterSettings; - private IdentityService identityService; @Mock private PerformanceAnalyzerController controller; @@ -64,15 +61,13 @@ public void init() { UsageService usageService = new UsageService(); threadPool = new TestThreadPool("test"); nodeClient = new NodeClient(Settings.EMPTY, threadPool); - identityService = new IdentityService(Settings.EMPTY, threadPool, List.of()); restController = new RestController( Collections.emptySet(), null, nodeClient, circuitBreakerService, - usageService, - identityService); + usageService); configAction = new PerformanceAnalyzerConfigAction(restController, controller); restController.registerHandler(configAction); diff --git a/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerOverridesClusterConfigActionTests.java b/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerOverridesClusterConfigActionTests.java index 16adf381..e5e43658 100644 --- a/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerOverridesClusterConfigActionTests.java +++ b/src/test/java/org/opensearch/performanceanalyzer/http_action/config/PerformanceAnalyzerOverridesClusterConfigActionTests.java @@ -13,7 +13,6 @@ import java.nio.ByteBuffer; import java.util.ArrayList; import java.util.Collections; -import java.util.List; import org.junit.After; import org.junit.Before; import org.junit.Test; @@ -27,7 +26,6 @@ import org.opensearch.core.indices.breaker.CircuitBreakerService; import org.opensearch.core.rest.RestStatus; import org.opensearch.core.xcontent.NamedXContentRegistry; -import org.opensearch.identity.IdentityService; import org.opensearch.indices.breaker.BreakerSettings; import org.opensearch.indices.breaker.HierarchyCircuitBreakerService; import org.opensearch.performanceanalyzer.commons.config.overrides.ConfigOverridesWrapper; @@ -48,7 +46,6 @@ public class PerformanceAnalyzerOverridesClusterConfigActionTests { private NodeClient nodeClient; private CircuitBreakerService circuitBreakerService; private ClusterSettings clusterSettings; - private IdentityService identityService; @Mock private ConfigOverridesClusterSettingHandler configOverridesClusterSettingHandler; @Mock private ConfigOverridesWrapper overridesWrapper; @@ -65,15 +62,13 @@ public void init() { UsageService usageService = new UsageService(); threadPool = new TestThreadPool("test"); nodeClient = new NodeClient(Settings.EMPTY, threadPool); - identityService = new IdentityService(Settings.EMPTY, threadPool, List.of()); restController = new RestController( Collections.emptySet(), null, nodeClient, circuitBreakerService, - usageService, - identityService); + usageService); configAction = new PerformanceAnalyzerOverridesClusterConfigAction( Settings.EMPTY,