Fix deprecated kotlin compiler configuration (#11501)
This commit is contained in:
parent
fc42cf9f1e
commit
a0526c436a
|
@ -1,4 +1,4 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
|
||||
plugins {
|
||||
id("org.jetbrains.kotlin.jvm")
|
||||
|
@ -44,12 +44,10 @@ dependencies {
|
|||
testLibrary("org.jetbrains.kotlinx:kotlinx-coroutines-reactor:1.0.0")
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
// generate metadata for Java 1.8 reflection on method parameters, used in @WithSpan tests
|
||||
javaParameters = true
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
// generate metadata for Java 1.8 reflection on method parameters, used in @WithSpan tests
|
||||
javaParameters = true
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
|
||||
// We are using a separate module for kotlin source instead of placing them in
|
||||
// instrumentation/kotlinx-coroutines/kotlinx-coroutines-flow-1.3/javaagent because muzzle
|
||||
|
@ -14,10 +14,8 @@ dependencies {
|
|||
compileOnly(project(":instrumentation-api"))
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
|
||||
plugins {
|
||||
id("org.jetbrains.kotlin.jvm")
|
||||
|
@ -36,13 +36,12 @@ dependencies {
|
|||
testLibrary("org.jetbrains.kotlinx:kotlinx-coroutines-reactor:1.3.0")
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
}
|
||||
withType<Test>().configureEach {
|
||||
jvmArgs("-Dio.opentelemetry.javaagent.shaded.io.opentelemetry.context.enableStrictContext=false")
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
}
|
||||
}
|
||||
|
||||
tasks.withType<Test>().configureEach {
|
||||
jvmArgs("-Dio.opentelemetry.javaagent.shaded.io.opentelemetry.context.enableStrictContext=false")
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
|
||||
|
||||
plugins {
|
||||
id("otel.library-instrumentation")
|
||||
|
@ -22,19 +23,14 @@ dependencies {
|
|||
latestDepTestLibrary("io.ktor:ktor-server-netty:1.+") // see ktor-2.0 module
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
}
|
||||
|
||||
compileKotlin {
|
||||
kotlinOptions {
|
||||
languageVersion = "1.4"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
@Suppress("deprecation")
|
||||
languageVersion.set(KotlinVersion.KOTLIN_1_4)
|
||||
}
|
||||
}
|
||||
|
||||
tasks.withType<Test>().configureEach {
|
||||
jvmArgs("-Dotel.instrumentation.common.experimental.controller-telemetry.enabled=true")
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
|
||||
plugins {
|
||||
id("org.jetbrains.kotlin.jvm")
|
||||
|
@ -33,10 +33,10 @@ dependencies {
|
|||
testLibrary("io.ktor:ktor-client-cio:$ktorVersion")
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
// generate metadata for Java 1.8 reflection on method parameters, used in @WithSpan tests
|
||||
javaParameters = true
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
|
||||
|
||||
plugins {
|
||||
id("otel.library-instrumentation")
|
||||
|
@ -24,16 +25,10 @@ dependencies {
|
|||
testLibrary("io.ktor:ktor-client-cio:$ktorVersion")
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
}
|
||||
|
||||
compileKotlin {
|
||||
kotlinOptions {
|
||||
languageVersion = "1.6"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
@Suppress("deprecation")
|
||||
languageVersion.set(KotlinVersion.KOTLIN_1_6)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
|
||||
plugins {
|
||||
id("otel.java-conventions")
|
||||
|
@ -21,10 +21,8 @@ dependencies {
|
|||
compileOnly("io.ktor:ktor-client-cio:$ktorVersion")
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
import org.jetbrains.kotlin.gradle.tasks.KotlinCompile
|
||||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
import org.jetbrains.kotlin.gradle.dsl.KotlinVersion
|
||||
|
||||
plugins {
|
||||
id("otel.library-instrumentation")
|
||||
|
@ -10,16 +11,10 @@ dependencies {
|
|||
testImplementation("org.jetbrains.kotlin:kotlin-stdlib-jdk8")
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
}
|
||||
|
||||
compileKotlin {
|
||||
kotlinOptions {
|
||||
languageVersion = "1.4"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
@Suppress("deprecation")
|
||||
languageVersion.set(KotlinVersion.KOTLIN_1_4)
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,3 +1,5 @@
|
|||
import org.jetbrains.kotlin.gradle.dsl.JvmTarget
|
||||
|
||||
plugins {
|
||||
id("org.jetbrains.kotlin.jvm")
|
||||
id("otel.javaagent-instrumentation")
|
||||
|
@ -42,10 +44,8 @@ if (!(findProperty("testLatestDeps") as Boolean)) {
|
|||
}
|
||||
}
|
||||
|
||||
tasks {
|
||||
withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile::class).configureEach {
|
||||
kotlinOptions {
|
||||
jvmTarget = "1.8"
|
||||
}
|
||||
kotlin {
|
||||
compilerOptions {
|
||||
jvmTarget.set(JvmTarget.JVM_1_8)
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue