Skip to content

Commit 13f0fee

Browse files
SOLR-17718: Upgrade bytebuddy to 1.17.4 (#3286)
Fixes cross-dc and cross-dc-manager tests when running with Java 25
1 parent a122401 commit 13f0fee

File tree

15 files changed

+35
-14
lines changed

15 files changed

+35
-14
lines changed

gradle/libs.versions.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -63,6 +63,7 @@ benmanes-versions = "0.51.0"
6363
bouncycastle = "1.78.1"
6464
# @keep Browserify version used in ref-guide
6565
browserify = "17.0.0"
66+
bytebuddy = "1.17.4"
6667
carrot2-core = "4.5.1"
6768
carrotsearch-hppc = "0.10.0"
6869
carrotsearch-randomizedtesting = "2.8.1"
@@ -294,6 +295,8 @@ bc-jose4j = { module = "org.bitbucket.b_c:jose4j", version.ref = "bc-jose4j" }
294295
benmanes-caffeine = { module = "com.github.ben-manes.caffeine:caffeine", version.ref = "benmanes-caffeine" }
295296
bouncycastle-bcpkix = { module = "org.bouncycastle:bcpkix-jdk18on", version.ref = "bouncycastle" }
296297
bouncycastle-bcprov = { module = "org.bouncycastle:bcprov-jdk18on", version.ref = "bouncycastle" }
298+
bytebuddy = { module = "net.bytebuddy:byte-buddy", version.ref = "bytebuddy" }
299+
bytebuddy-agent = { module = "net.bytebuddy:byte-buddy-agent", version.ref = "bytebuddy" }
297300
carrot2-core = { module = "org.carrot2:carrot2-core", version.ref = "carrot2-core" }
298301
carrotsearch-hppc = { module = "com.carrotsearch:hppc", version.ref = "carrotsearch-hppc" }
299302
carrotsearch-randomizedtesting-runner = { module = "com.carrotsearch.randomizedtesting:randomizedtesting-runner", version.ref = "carrotsearch-randomizedtesting" }

solr/core/gradle.lockfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ jakarta.xml.bind:jakarta.xml.bind-api:4.0.2=permitUnusedDeclared
7878
javax.inject:javax.inject:1=annotationProcessor,errorprone,testAnnotationProcessor
7979
javax.servlet:javax.servlet-api:3.1.0=permitUnusedDeclared
8080
junit:junit:4.13.2=jarValidation,testCompileClasspath,testRuntimeClasspath
81-
net.bytebuddy:byte-buddy:1.15.11=jarValidation,testCompileClasspath,testRuntimeClasspath
81+
net.bytebuddy:byte-buddy:1.17.4=jarValidation,testCompileClasspath,testRuntimeClasspath
8282
org.antlr:antlr4-runtime:4.11.1=jarValidation,runtimeClasspath,runtimeLibs,testRuntimeClasspath
8383
org.apache.commons:commons-exec:1.4.0=compileClasspath,jarValidation,runtimeClasspath,runtimeLibs,testCompileClasspath,testRuntimeClasspath
8484
org.apache.commons:commons-lang3:3.15.0=compileClasspath,jarValidation,runtimeClasspath,runtimeLibs,testCompileClasspath,testRuntimeClasspath

solr/cross-dc-manager/build.gradle

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,16 @@ dependencies {
4949
testImplementation libs.apache.lucene.testframework
5050
testImplementation libs.carrotsearch.randomizedtesting.runner
5151
testImplementation libs.junit.junit
52-
testImplementation libs.mockito.core
52+
// The explicit dependency on bytebuddy is required for Java 25 support
53+
// Once Mockito upgrades its dependency on ByteBuddy to 1.16.1, we should
54+
// be able to remove this and merely use:
55+
// testImplementation libs.mockito.core
56+
testImplementation(libs.mockito.core, {
57+
exclude group: "net.bytebuddy", module: "byte-buddy"
58+
exclude group: "net.bytebuddy", module: "byte-buddy-agent"
59+
})
60+
testRuntimeOnly libs.bytebuddy
61+
testRuntimeOnly libs.bytebuddy.agent
5362

5463
testImplementation(libs.apache.kafka.streams) {
5564
artifact {

solr/cross-dc-manager/gradle.lockfile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -83,8 +83,8 @@ jakarta.validation:jakarta.validation-api:3.0.2=jarValidation,runtimeClasspath,r
8383
jakarta.ws.rs:jakarta.ws.rs-api:3.1.0=jarValidation,runtimeClasspath,runtimeLibs,solrPlatformLibs,testRuntimeClasspath
8484
javax.inject:javax.inject:1=annotationProcessor,errorprone,testAnnotationProcessor
8585
junit:junit:4.13.2=jarValidation,testCompileClasspath,testRuntimeClasspath
86-
net.bytebuddy:byte-buddy-agent:1.15.11=jarValidation,testCompileClasspath,testRuntimeClasspath
87-
net.bytebuddy:byte-buddy:1.15.11=jarValidation,testCompileClasspath,testRuntimeClasspath
86+
net.bytebuddy:byte-buddy-agent:1.17.4=jarValidation,testRuntimeClasspath
87+
net.bytebuddy:byte-buddy:1.17.4=jarValidation,testRuntimeClasspath
8888
net.sf.jopt-simple:jopt-simple:5.0.4=jarValidation,runtimeClasspath,runtimeLibs,testRuntimeClasspath
8989
net.sourceforge.argparse4j:argparse4j:0.7.0=jarValidation,runtimeClasspath,runtimeLibs,testRuntimeClasspath
9090
org.antlr:antlr4-runtime:4.11.1=jarValidation,runtimeClasspath,runtimeLibs,solrPlatformLibs,testRuntimeClasspath

solr/licenses/byte-buddy-1.15.11.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
ffb8488d93290eff074fb542a596e4c5a26d0315

solr/licenses/byte-buddy-agent-1.15.11.jar.sha1

Lines changed: 0 additions & 1 deletion
This file was deleted.
Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
9dd4f0adf859ffc402508141fcbe940551ffa3b6

solr/modules/analysis-extras/gradle.lockfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ jakarta.validation:jakarta.validation-api:3.0.2=apiHelper,jarValidation,runtimeC
6767
jakarta.ws.rs:jakarta.ws.rs-api:3.1.0=apiHelper,jarValidation,runtimeClasspath,runtimeLibs,solrPlatformLibs,testRuntimeClasspath
6868
javax.inject:javax.inject:1=annotationProcessor,errorprone,testAnnotationProcessor
6969
junit:junit:4.13.2=jarValidation,testCompileClasspath,testRuntimeClasspath
70-
net.bytebuddy:byte-buddy:1.15.11=jarValidation,testCompileClasspath,testRuntimeClasspath
70+
net.bytebuddy:byte-buddy:1.17.4=jarValidation,testCompileClasspath,testRuntimeClasspath
7171
org.antlr:antlr4-runtime:4.11.1=apiHelper,jarValidation,runtimeClasspath,runtimeLibs,solrPlatformLibs,testRuntimeClasspath
7272
org.apache.commons:commons-exec:1.4.0=apiHelper,jarValidation,runtimeClasspath,runtimeLibs,solrPlatformLibs,testRuntimeClasspath
7373
org.apache.commons:commons-lang3:3.15.0=apiHelper,jarValidation,runtimeClasspath,runtimeLibs,solrPlatformLibs,testRuntimeClasspath

solr/modules/cross-dc/build.gradle

Lines changed: 10 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,8 +44,17 @@ dependencies {
4444
testImplementation libs.apache.lucene.testframework
4545
testImplementation libs.junit.junit
4646
testImplementation libs.commonsio.commonsio
47-
testImplementation libs.mockito.core
4847
testImplementation libs.carrotsearch.randomizedtesting.runner
48+
// The explicit dependency on bytebuddy is required for Java 25 support
49+
// Once Mockito upgrades its dependency on ByteBuddy to 1.16.1, we should
50+
// be able to remove this and merely use:
51+
// testImplementation libs.mockito.core
52+
testImplementation(libs.mockito.core, {
53+
exclude group: "net.bytebuddy", module: "byte-buddy"
54+
exclude group: "net.bytebuddy", module: "byte-buddy-agent"
55+
})
56+
testRuntimeOnly libs.bytebuddy
57+
testRuntimeOnly libs.bytebuddy.agent
4958

5059
testImplementation(libs.apache.kafka.clients) {
5160
artifact {

0 commit comments

Comments
 (0)