Update spotless version
MODIFY
benchmark-overhead/build.gradle.kts
benchmark-overhead/build.gradle.kts
plugins {
id("java")
- id("com.diffplug.spotless") version "6.7.2"
+ id("com.diffplug.spotless") version "6.9.0"
}
spotless {

MODIFY
conventions/build.gradle.kts
conventions/build.gradle.kts
plugins {
`kotlin-dsl`
// When updating, update below in dependencies too
- id("com.diffplug.spotless") version "6.7.2"
+ id("com.diffplug.spotless") version "6.9.0"
}
spotless {
@@ -11,7 +11,8 @@ spotless {
target("src/**/*.java")
}
kotlinGradle {
- ktlint().userData(mapOf("indent_size" to "2", "continuation_indent_size" to "2", "disabled_rules" to "no-wildcard-imports"))
+ // not sure why it's not using the indent settings from .editorconfig
+ ktlint().editorConfigOverride(mapOf("indent_size" to "2", "continuation_indent_size" to "2", "disabled_rules" to "no-wildcard-imports"))
target("**/*.gradle.kts")
}
}
@@ -39,7 +40,7 @@ dependencies {
implementation("org.apache.maven:maven-aether-provider:3.3.9")
// When updating, update above in plugins too
- implementation("com.diffplug.spotless:spotless-plugin-gradle:6.7.2")
+ implementation("com.diffplug.spotless:spotless-plugin-gradle:6.9.0")
implementation("com.google.guava:guava:31.1-jre")
implementation("gradle.plugin.com.google.protobuf:protobuf-gradle-plugin:0.8.18")
implementation("gradle.plugin.com.github.johnrengelman:shadow:7.1.2")

MODIFY
conventions/src/main/kotlin/otel.spotless-conventions.gradle.kts
conventions/src/main/kotlin/otel.spotless-conventions.gradle.kts
@@ -25,14 +25,14 @@ spotless {
}
plugins.withId("org.jetbrains.kotlin.jvm") {
kotlin {
- ktlint().userData(mapOf("continuation_indent_size" to "2", "disabled_rules" to "no-wildcard-imports"))
- .editorConfigOverride(mapOf("indent_size" to "2")) // not sure why it's not using the setting from .editorconfig
+ // not sure why it's not using the indent settings from .editorconfig
+ ktlint().editorConfigOverride(mapOf("indent_size" to "2", "continuation_indent_size" to "2", "disabled_rules" to "no-wildcard-imports,package-name"))
licenseHeaderFile(rootProject.file("buildscripts/spotless.license.java"), "(package|import|class|// Includes work from:)")
}
}
kotlinGradle {
- ktlint().userData(mapOf("continuation_indent_size" to "2", "disabled_rules" to "no-wildcard-imports"))
- .editorConfigOverride(mapOf("indent_size" to "2")) // not sure why it's not using the setting from .editorconfig
+ // not sure why it's not using the indent settings from .editorconfig
+ ktlint().editorConfigOverride(mapOf("indent_size" to "2", "continuation_indent_size" to "2", "disabled_rules" to "no-wildcard-imports"))
}
format("misc") {
// not using "**/..." to help keep spotless fast

MODIFY
custom-checks/build.gradle.kts
custom-checks/build.gradle.kts
@@ -33,10 +33,14 @@ tasks {
compilerArgs.addAll(
listOf(
- "--add-exports", "jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED",
- "--add-exports", "jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED",
- "--add-exports", "jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED",
- "--add-exports", "jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"
+ "--add-exports",
+ "jdk.compiler/com.sun.tools.javac.api=ALL-UNNAMED",
+ "--add-exports",
+ "jdk.compiler/com.sun.tools.javac.comp=ALL-UNNAMED",
+ "--add-exports",
+ "jdk.compiler/com.sun.tools.javac.tree=ALL-UNNAMED",
+ "--add-exports",
+ "jdk.compiler/com.sun.tools.javac.util=ALL-UNNAMED"
)
)
}

MODIFY
instrumentation/kotlinx-coroutines/javaagent/src/test/kotlin/io/opentelemetry/javaagent/instrumentation/kotlinxcoroutines/KotlinCoroutinesInstrumentationTest.kt
instrumentation/kotlinx-coroutines/javaagent/src/test/kotlin/io/opentelemetry/javaagent/instrumentation/kotlinxcoroutines/KotlinCoroutinesInstrumentationTest.kt
@@ -127,7 +127,7 @@ class KotlinCoroutinesInstrumentationTest {
assertThat(it)
.hasName("consume_2")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -160,7 +160,7 @@ class KotlinCoroutinesInstrumentationTest {
{
it.hasName("preLaunch")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -188,7 +188,7 @@ class KotlinCoroutinesInstrumentationTest {
{
it.hasName("nested")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -244,7 +244,7 @@ class KotlinCoroutinesInstrumentationTest {
Consumer {
assertThat(it).hasName("brokenPromise")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -300,7 +300,7 @@ class KotlinCoroutinesInstrumentationTest {
assertThat(it)
.hasName("timeout3")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -338,7 +338,7 @@ class KotlinCoroutinesInstrumentationTest {
assertThat(it)
.hasName("a2")
.hasParent(trace.get(0))
- },
+ }
)
}
assertions.add { trace ->
@@ -352,7 +352,7 @@ class KotlinCoroutinesInstrumentationTest {
assertThat(it)
.hasName("b2")
.hasParent(trace.get(0))
- },
+ }
)
}
}
@@ -382,7 +382,7 @@ class KotlinCoroutinesInstrumentationTest {
{
it.hasName("child")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -417,7 +417,7 @@ class KotlinCoroutinesInstrumentationTest {
{
it.hasName("child")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -454,7 +454,7 @@ class KotlinCoroutinesInstrumentationTest {
{
it.hasName("child_2")
.hasParent(trace.getSpan(0))
- },
+ }
)
}
)
@@ -526,7 +526,7 @@ class KotlinCoroutinesInstrumentationTest {
arguments(DispatcherWrapper(Dispatchers.IO)),
arguments(DispatcherWrapper(Dispatchers.Unconfined)),
arguments(DispatcherWrapper(threadPool.asCoroutineDispatcher())),
- arguments(DispatcherWrapper(singleThread.asCoroutineDispatcher())),
+ arguments(DispatcherWrapper(singleThread.asCoroutineDispatcher()))
)
}

RENAME
instrumentation/ktor/ktor-common/library/src/main/kotlin/io/opentelemetry/instrumentation/ktor/IpAddressUtil.kt
instrumentation/ktor/ktor-common/library/src/main/kotlin/io/opentelemetry/instrumentation/ktor/IsIpAddress.kt
MODIFY
smoke-tests/images/servlet/build.gradle.kts
smoke-tests/images/servlet/build.gradle.kts
@@ -23,18 +23,18 @@ val targets = mapOf(
ImageTarget(listOf("10.0.7"), listOf("hotspot"), listOf("11", "17", "18", "19"), mapOf("sourceVersion" to "10.0.7")),
ImageTarget(listOf("10.0.7"), listOf("openj9"), listOf("11", "16"), mapOf("sourceVersion" to "10.0.7")),
ImageTarget(listOf("11.0.7"), listOf("hotspot"), listOf("11", "17", "18", "19"), mapOf("sourceVersion" to "11.0.7"), "servlet-5.0"),
- ImageTarget(listOf("11.0.7"), listOf("openj9"), listOf("11", "16"), mapOf("sourceVersion" to "11.0.7"), "servlet-5.0"),
+ ImageTarget(listOf("11.0.7"), listOf("openj9"), listOf("11", "16"), mapOf("sourceVersion" to "11.0.7"), "servlet-5.0")
),
"liberty" to listOf(
// running configure.sh is failing while building the image with Java 17
ImageTarget(listOf("20.0.0.12"), listOf("hotspot", "openj9"), listOf("8", "11", "16"), mapOf("release" to "2020-11-11_0736")),
// running configure.sh is failing while building the image with Java 18
ImageTarget(listOf("21.0.0.10"), listOf("hotspot"), listOf("8", "11", "17"), mapOf("release" to "2021-09-20_1900")),
- ImageTarget(listOf("21.0.0.10"), listOf("openj9"), listOf("8", "11", "16"), mapOf("release" to "2021-09-20_1900")),
+ ImageTarget(listOf("21.0.0.10"), listOf("openj9"), listOf("8", "11", "16"), mapOf("release" to "2021-09-20_1900"))
),
"payara" to listOf(
ImageTarget(listOf("5.2020.6"), listOf("hotspot", "openj9"), listOf("8", "11")),
- ImageTarget(listOf("5.2021.8"), listOf("hotspot", "openj9"), listOf("8", "11")),
+ ImageTarget(listOf("5.2021.8"), listOf("hotspot", "openj9"), listOf("8", "11"))
),
"tomcat" to listOf(
// TODO (trask) remove Java 18 test once Java 19 is GA
@@ -44,7 +44,7 @@ val targets = mapOf(
ImageTarget(listOf("9.0.54"), listOf("hotspot"), listOf("8", "11", "17", "18", "19"), mapOf("majorVersion" to "9")),
ImageTarget(listOf("9.0.54"), listOf("openj9"), listOf("8", "11"), mapOf("majorVersion" to "9")),
ImageTarget(listOf("10.0.12"), listOf("hotspot"), listOf("8", "11", "17", "18", "19"), mapOf("majorVersion" to "10"), "servlet-5.0"),
- ImageTarget(listOf("10.0.12"), listOf("openj9"), listOf("8", "11"), mapOf("majorVersion" to "10"), "servlet-5.0"),
+ ImageTarget(listOf("10.0.12"), listOf("openj9"), listOf("8", "11"), mapOf("majorVersion" to "10"), "servlet-5.0")
),
"tomee" to listOf(
// TODO (trask) remove Java 18 test once Java 19 is GA
@@ -53,19 +53,19 @@ val targets = mapOf(
ImageTarget(listOf("8.0.8"), listOf("hotspot"), listOf("8", "11", "17", "18", "19")),
ImageTarget(listOf("8.0.8"), listOf("openj9"), listOf("8", "11", "16")),
ImageTarget(listOf("9.0.0-M7"), listOf("hotspot"), listOf("8", "11", "17", "18", "19"), war = "servlet-5.0"),
- ImageTarget(listOf("9.0.0-M7"), listOf("openj9"), listOf("8", "11", "16"), war = "servlet-5.0"),
+ ImageTarget(listOf("9.0.0-M7"), listOf("openj9"), listOf("8", "11", "16"), war = "servlet-5.0")
),
"websphere" to listOf(
// TODO (trask) this is a recent change, check back in a while and see if it's been fixed
// 8.5.5.20 only has linux/ppc64le image
- ImageTarget(listOf("8.5.5.19", "9.0.5.9"), listOf("openj9"), listOf("8"), windows = false),
+ ImageTarget(listOf("8.5.5.19", "9.0.5.9"), listOf("openj9"), listOf("8"), windows = false)
),
"wildfly" to listOf(
// TODO (trask) remove Java 18 test once Java 19 is GA
ImageTarget(listOf("13.0.0.Final"), listOf("hotspot", "openj9"), listOf("8")),
ImageTarget(listOf("17.0.1.Final", "21.0.0.Final", "25.0.1.Final"), listOf("hotspot"), listOf("8", "11", "17", "18", "19")),
- ImageTarget(listOf("17.0.1.Final", "21.0.0.Final", "25.0.1.Final"), listOf("openj9"), listOf("8", "11", "16")),
- ),
+ ImageTarget(listOf("17.0.1.Final", "21.0.0.Final", "25.0.1.Final"), listOf("openj9"), listOf("8", "11", "16"))
+ )
)
val matrix = mutableListOf<String>()

Update spotless version (#6421)