Skip to content

Commit

Permalink
Update bundled JDK to JDK-21.0.1 (opensearch-project#10576)
Browse files Browse the repository at this point in the history
Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
(cherry picked from commit 0d7d1e9)
Signed-off-by: Andriy Redko <andriy.redko@aiven.io>
  • Loading branch information
reta committed Nov 10, 2023
1 parent 822e253 commit 3d508c4
Show file tree
Hide file tree
Showing 5 changed files with 33 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,9 @@
import java.util.stream.Stream;

public class DistroTestPlugin implements Plugin<Project> {
private static final String SYSTEM_JDK_VERSION = "11.0.20+8";
private static final String SYSTEM_JDK_VERSION = "17.0.9+9";
private static final String SYSTEM_JDK_VENDOR = "adoptium";
private static final String GRADLE_JDK_VERSION = "17.0.8+7";
private static final String GRADLE_JDK_VERSION = "17.0.9+9";
private static final String GRADLE_JDK_VENDOR = "adoptium";

// all distributions used by distro tests. this is temporary until tests are per distribution
Expand Down
2 changes: 1 addition & 1 deletion buildSrc/version.properties
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ opensearch = 2.12.0
lucene = 9.8.0

bundled_jdk_vendor = adoptium
bundled_jdk = 17.0.8+7
bundled_jdk = 21.0.1+12

# optional dependencies
spatial4j = 0.7
Expand Down
2 changes: 1 addition & 1 deletion distribution/src/config/jvm.options
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ ${error.file}

# JDK 20+ Incubating Vector Module for SIMD optimizations;
# disabling may reduce performance on vector optimized lucene
20:--add-modules=jdk.incubator.vector
20-:--add-modules=jdk.incubator.vector

# HDFS ForkJoinPool.common() support by SecurityManager
-Djava.util.concurrent.ForkJoinPool.common.threadFactory=org.opensearch.secure_sm.SecuredForkJoinWorkerThreadFactory
27 changes: 17 additions & 10 deletions libs/core/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -104,16 +104,23 @@ tasks.named('forbiddenApisMain').configure {
tasks.named("thirdPartyAudit").configure {
ignoreMissingClasses(
// from log4j
'org.osgi.framework.Bundle',
'org.osgi.framework.BundleActivator',
'org.osgi.framework.BundleContext',
'org.osgi.framework.BundleEvent',
'org.osgi.framework.FrameworkUtil',
'org.osgi.framework.ServiceReference',
'org.osgi.framework.ServiceRegistration',
'org.osgi.framework.SynchronousBundleListener',
'org.osgi.framework.wiring.BundleWire',
'org.osgi.framework.wiring.BundleWiring'
*[
'org.osgi.framework.Bundle',
'org.osgi.framework.BundleActivator',
'org.osgi.framework.BundleContext',
'org.osgi.framework.BundleEvent',
'org.osgi.framework.SynchronousBundleListener',
'org.osgi.framework.wiring.BundleWire',
'org.osgi.framework.wiring.BundleWiring',
] + (BuildParams.runtimeJavaVersion < JavaVersion.VERSION_20) ? [] : [
'jdk.incubator.vector.ByteVector',
'jdk.incubator.vector.FloatVector',
'jdk.incubator.vector.IntVector',
'jdk.incubator.vector.ShortVector',
'jdk.incubator.vector.Vector',
'jdk.incubator.vector.VectorOperators',
'jdk.incubator.vector.VectorSpecies'
]
)
}

Expand Down
13 changes: 12 additions & 1 deletion server/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -257,6 +257,7 @@ tasks.named("processResources").configure {

tasks.named("thirdPartyAudit").configure {
ignoreMissingClasses(
*[
// from com.fasterxml.jackson.dataformat.yaml.YAMLMapper (jackson-dataformat-yaml)
'com.fasterxml.jackson.databind.ObjectMapper',

Expand Down Expand Up @@ -385,7 +386,17 @@ tasks.named("thirdPartyAudit").configure {
'org.slf4j.Logger',
'org.slf4j.LoggerFactory',
'reactor.blockhound.BlockHound$Builder',
'reactor.blockhound.integration.BlockHoundIntegration'
'reactor.blockhound.integration.BlockHoundIntegration',
'com.google.common.geometry.S2LatLng'
] + (BuildParams.runtimeJavaVersion < JavaVersion.VERSION_20) ? [] : [
'jdk.incubator.vector.ByteVector',
'jdk.incubator.vector.FloatVector',
'jdk.incubator.vector.IntVector',
'jdk.incubator.vector.ShortVector',
'jdk.incubator.vector.Vector',
'jdk.incubator.vector.VectorOperators',
'jdk.incubator.vector.VectorSpecies'
]
)
ignoreViolations(
'com.google.protobuf.MessageSchema',
Expand Down

0 comments on commit 3d508c4

Please sign in to comment.