From 33335f7dc6f2eea585918e9bb61a1684c27d38aa Mon Sep 17 00:00:00 2001 From: Suraj Singh Date: Tue, 6 Jun 2023 16:16:47 -0700 Subject: [PATCH] Address review comments Signed-off-by: Suraj Singh --- distribution/build.gradle | 2 +- gradle/runtime-jdk-provision.gradle | 2 +- .../indices/replication/SegmentReplicationIT.java | 9 ++++++++- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/distribution/build.gradle b/distribution/build.gradle index 2378ed833ead7..631813aadd615 100644 --- a/distribution/build.gradle +++ b/distribution/build.gradle @@ -283,7 +283,7 @@ configure(subprojects.findAll { ['archives', 'packages'].contains(it.name) }) { (platform == 'linux' || platform == 'darwin' ? ['x64', 'aarch64', 's390x', 'ppc64le'] : ['x64']).each { architecture -> "bundled_${platform}_${architecture}" { it.platform = platform - it.version = VersionProperties.getBundledJdk(platform, architecture) + it.version = VersionProperties.getBundledJdk(platform) it.vendor = VersionProperties.bundledJdkVendor it.architecture = architecture } diff --git a/gradle/runtime-jdk-provision.gradle b/gradle/runtime-jdk-provision.gradle index 6bff164633c25..cb4bb834f89c9 100644 --- a/gradle/runtime-jdk-provision.gradle +++ b/gradle/runtime-jdk-provision.gradle @@ -32,7 +32,7 @@ if (BuildParams.getIsRuntimeJavaHomeSet()) { jdks { provisioned_runtime { vendor = VersionProperties.bundledJdkVendor - version = VersionProperties.getBundledJdk(OS.current().name().toLowerCase(), Architecture.current().name().toLowerCase()) + version = VersionProperties.getBundledJdk(OS.current().name().toLowerCase()) platform = OS.current().name().toLowerCase() architecture = Architecture.current().name().toLowerCase() } diff --git a/server/src/internalClusterTest/java/org/opensearch/indices/replication/SegmentReplicationIT.java b/server/src/internalClusterTest/java/org/opensearch/indices/replication/SegmentReplicationIT.java index bdd8320a412d1..a4f63635d2649 100644 --- a/server/src/internalClusterTest/java/org/opensearch/indices/replication/SegmentReplicationIT.java +++ b/server/src/internalClusterTest/java/org/opensearch/indices/replication/SegmentReplicationIT.java @@ -203,7 +203,14 @@ public void testCancelPrimaryAllocation() throws Exception { public void testReplicationAfterPrimaryRefreshAndFlush() throws Exception { final String nodeA = internalCluster().startNode(); final String nodeB = internalCluster().startNode(); - createIndex(INDEX_NAME); + final Settings settings = Settings.builder() + .put(indexSettings()) + .put( + EngineConfig.INDEX_CODEC_SETTING.getKey(), + randomFrom(CodecService.DEFAULT_CODEC, CodecService.BEST_COMPRESSION_CODEC, CodecService.LUCENE_DEFAULT_CODEC) + ) + .build(); + createIndex(INDEX_NAME, settings); ensureGreen(INDEX_NAME); final int initialDocCount = scaledRandomIntBetween(0, 200);