Skip to content

Commit ca3919e

Browse files
authored
Update Gradle and build dependencies (#4808)
* Update Gradle and build dependencies * Add spotless + Java 17 workaround * Revert spotless for now * Fix merge * jvmTarget
1 parent 3801bb3 commit ca3919e

File tree

6 files changed

+40
-23
lines changed

6 files changed

+40
-23
lines changed

conventions/build.gradle.kts

Lines changed: 11 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -38,23 +38,24 @@ dependencies {
3838

3939
// When updating, update above in plugins too
4040
implementation("com.diffplug.spotless:spotless-plugin-gradle:5.16.0")
41-
implementation("com.google.guava:guava:30.1-jre")
41+
implementation("com.google.guava:guava:31.0.1-jre")
4242
implementation("gradle.plugin.com.google.protobuf:protobuf-gradle-plugin:0.8.18")
43-
implementation("gradle.plugin.com.github.jengelman.gradle.plugins:shadow:7.0.0")
43+
implementation("gradle.plugin.com.github.johnrengelman:shadow:7.1.0")
4444
implementation("org.ow2.asm:asm:9.1")
4545
implementation("org.ow2.asm:asm-tree:9.1")
4646
implementation("org.apache.httpcomponents:httpclient:4.5.13")
47-
implementation("org.gradle:test-retry-gradle-plugin:1.2.1")
48-
implementation("ru.vyarus:gradle-animalsniffer-plugin:1.5.3")
47+
implementation("org.gradle:test-retry-gradle-plugin:1.3.1")
48+
implementation("ru.vyarus:gradle-animalsniffer-plugin:1.5.4")
4949
// When updating, also update dependencyManagement/build.gradle.kts
5050
implementation("net.bytebuddy:byte-buddy-gradle-plugin:1.11.22")
5151
implementation("gradle.plugin.io.morethan.jmhreport:gradle-jmh-report:0.9.0")
52-
implementation("me.champeau.jmh:jmh-gradle-plugin:0.6.5")
53-
implementation("net.ltgt.gradle:gradle-errorprone-plugin:2.0.1")
54-
implementation("net.ltgt.gradle:gradle-nullaway-plugin:1.1.0")
52+
implementation("me.champeau.jmh:jmh-gradle-plugin:0.6.6")
53+
implementation("net.ltgt.gradle:gradle-errorprone-plugin:2.0.2")
54+
implementation("net.ltgt.gradle:gradle-nullaway-plugin:1.2.0")
5555
implementation("me.champeau.gradle:japicmp-gradle-plugin:0.3.0")
5656

57-
testImplementation("org.junit.jupiter:junit-jupiter-api:5.7.2")
58-
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine:5.7.2")
59-
testImplementation("org.assertj:assertj-core:3.19.0")
57+
testImplementation(enforcedPlatform("org.junit:junit-bom:5.8.2"))
58+
testImplementation("org.junit.jupiter:junit-jupiter-api")
59+
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")
60+
testImplementation("org.assertj:assertj-core:3.21.0")
6061
}

gradle-plugins/build.gradle.kts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ configurations.named("compileOnly") {
2323
}
2424

2525
dependencies {
26-
implementation("com.google.guava:guava:30.1.1-jre")
26+
implementation("com.google.guava:guava:31.0.1-jre")
2727
// we need to use byte buddy variant that does not shade asm
2828
implementation("net.bytebuddy:byte-buddy-gradle-plugin:1.11.22") {
2929
exclude(group = "net.bytebuddy", module = "byte-buddy")
@@ -34,11 +34,11 @@ dependencies {
3434
implementation("org.eclipse.aether:aether-transport-http:1.1.0")
3535
implementation("org.apache.maven:maven-aether-provider:3.3.9")
3636

37-
implementation("gradle.plugin.com.github.jengelman.gradle.plugins:shadow:7.0.0")
37+
implementation("gradle.plugin.com.github.johnrengelman:shadow:7.1.0")
3838

39-
testImplementation("org.assertj:assertj-core:3.19.0")
39+
testImplementation("org.assertj:assertj-core:3.21.0")
4040

41-
testImplementation(enforcedPlatform("org.junit:junit-bom:5.7.2"))
41+
testImplementation(enforcedPlatform("org.junit:junit-bom:5.8.2"))
4242
testImplementation("org.junit.jupiter:junit-jupiter-api")
4343
testImplementation("org.junit.jupiter:junit-jupiter-params")
4444
testRuntimeOnly("org.junit.jupiter:junit-jupiter-engine")

gradle.properties

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,18 @@ org.gradle.caching=true
44
org.gradle.priority=low
55

66
# Gradle default is 256m which causes issues with our build - https://docs.gradle.org/current/userguide/build_environment.html#sec:configuring_jvm_memory
7-
org.gradle.jvmargs=-XX:MaxMetaspaceSize=512m
7+
# Also workaround https://github.com/diffplug/spotless/issues/834
8+
org.gradle.jvmargs=-XX:MaxMetaspaceSize=512m \
9+
--add-exports jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED \
10+
--add-exports jdk.compiler/com.sun.tools.javac.file=ALL-UNNAMED \
11+
--add-exports=jdk.compiler/com.sun.tools.javac.main=ALL-UNNAMED \
12+
--add-exports=jdk.compiler/com.sun.tools.javac.model=ALL-UNNAMED \
13+
--add-exports jdk.compiler/com.sun.tools.javac.parser=ALL-UNNAMED \
14+
--add-exports=jdk.compiler/com.sun.tools.javac.processing=ALL-UNNAMED \
15+
--add-exports jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED \
16+
--add-exports jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED \
17+
--add-opens=jdk.compiler/com.sun.tools.javac.code=ALL-UNNAMED \
18+
--add-opens=jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED
819

920
org.gradle.warning.mode=fail
1021

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
distributionBase=GRADLE_USER_HOME
22
distributionPath=wrapper/dists
3-
distributionSha256Sum=de8f52ad49bdc759164f72439a3bf56ddb1589c4cde802d3cec7d6ad0e0ee410
4-
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3-bin.zip
3+
distributionSha256Sum=9afb3ca688fc12c761a0e9e4321e4d24e977a4a8916c8a768b1fe05ddb4d6b66
4+
distributionUrl=https\://services.gradle.org/distributions/gradle-7.3.1-bin.zip
55
zipStoreBase=GRADLE_USER_HOME
66
zipStorePath=wrapper/dists

instrumentation/kotlinx-coroutines/javaagent/build.gradle.kts

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,5 @@
1+
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
2+
13
plugins {
24
id("org.jetbrains.kotlin.jvm")
35
id("otel.javaagent-instrumentation")
@@ -27,6 +29,12 @@ dependencies {
2729
}
2830

2931
tasks {
32+
withType(KotlinCompile::class).configureEach {
33+
kotlinOptions {
34+
jvmTarget = "1.8"
35+
}
36+
}
37+
3038
val compileTestKotlin by existing(AbstractCompile::class)
3139

3240
named<GroovyCompile>("compileTestGroovy") {

settings.gradle.kts

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,12 @@
11
pluginManagement {
22
plugins {
33
id("com.github.ben-manes.versions") version "0.39.0"
4-
id("com.github.jk1.dependency-license-report") version "1.16"
5-
id("com.gradle.plugin-publish") version "0.15.0"
4+
id("com.github.jk1.dependency-license-report") version "2.0"
5+
id("com.gradle.plugin-publish") version "0.18.0"
66
id("io.github.gradle-nexus.publish-plugin") version "1.1.0"
7-
id("me.champeau.jmh") version "0.6.5"
8-
id("org.jetbrains.kotlin.jvm") version "1.5.10"
7+
id("org.jetbrains.kotlin.jvm") version "1.6.0"
98
id("org.unbroken-dome.test-sets") version "4.0.0"
109
id("org.xbib.gradle.plugin.jflex") version "1.5.0"
11-
id("com.github.johnrengelman.shadow") version "7.0.0"
12-
id("ru.vyarus.animalsniffer") version "1.5.3"
1310
}
1411
}
1512

0 commit comments

Comments
 (0)