Skip to content

Commit cc51bfc

Browse files
authored
chore: upgrade to gradle 8.5 (#84)
1 parent c3502be commit cc51bfc

22 files changed

+112
-145
lines changed

aws-crt-kotlin/build.gradle.kts

Lines changed: 13 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,11 @@
33
* SPDX-License-Identifier: Apache-2.0
44
*/
55
import aws.sdk.kotlin.gradle.dsl.configurePublishing
6+
import aws.sdk.kotlin.gradle.kmp.IDEA_ACTIVE
67
import aws.sdk.kotlin.gradle.kmp.configureKmpTargets
78

89
plugins {
9-
kotlin("multiplatform")
10+
alias(libs.plugins.kotlin.multiplatform)
1011
}
1112

1213
val sdkVersion: String by project
@@ -17,9 +18,6 @@ description = "Kotlin Multiplatform bindings for AWS SDK Common Runtime"
1718
// See: https://kotlinlang.org/docs/reference/opt-in-requirements.html#opting-in-to-using-api
1819
val optinAnnotations = listOf("kotlin.RequiresOptIn")
1920

20-
val ideaActive = System.getProperty("idea.active") == "true"
21-
extra["ideaActive"] = ideaActive
22-
2321
// KMP configuration from build plugin
2422
configureKmpTargets()
2523

@@ -44,7 +42,7 @@ kotlin {
4442
// See:
4543
// * https://kotlinlang.org/docs/mpp-share-on-platforms.html#share-code-in-libraries
4644
// * https://kotlinlang.org/docs/mpp-set-up-targets.html#distinguish-several-targets-for-one-platform
47-
if (!ideaActive) {
45+
if (!IDEA_ACTIVE) {
4846

4947
// NOTE: We don't actually need the Android plugin. All of the Android specifics are handled in aws-crt-java,
5048
// we just need a variant with a different dependency set + some distinguishing attributes.
@@ -69,42 +67,41 @@ kotlin {
6967
sourceSets {
7068
val commonMain by getting {
7169
dependencies {
72-
implementation(kotlin("stdlib-common"))
73-
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:$coroutinesVersion")
70+
implementation(libs.kotlin.stdlib)
71+
implementation(libs.kotlinx.coroutines.core)
7472
}
7573
}
7674

7775
val jvmMain by getting {
7876
dependencies {
79-
val crtJavaVersion: String by project
80-
implementation("software.amazon.awssdk.crt:aws-crt:$crtJavaVersion")
77+
implementation(libs.crt.java)
8178

8279
// FIXME - temporary integration with CompletableFuture while we work out a POC on the jvm target
83-
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-jdk8:$coroutinesVersion")
80+
implementation(libs.kotlinx.coroutines.jdk8)
8481
}
8582
}
8683

8784
val jvmTest by getting {
8885
dependencies {
89-
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-debug:$coroutinesVersion")
90-
implementation("org.mock-server:mockserver-netty:$mockServerVersion")
86+
implementation(libs.kotlinx.coroutines.debug)
87+
implementation(libs.mockserver.netty)
9188
}
9289
}
9390

94-
if (!ideaActive) {
91+
if (!IDEA_ACTIVE) {
9592
val androidMain by getting {
9693
// re-use the jvm (desktop) sourceSet. We only really care about declaring a variant with a different set
9794
// of runtime dependencies
9895
kotlin.srcDir("jvm/src")
9996
dependsOn(commonMain)
10097
dependencies {
101-
val crtJavaVersion: String by project
10298
// we need symbols we can resolve during compilation but at runtime (i.e. on device) we depend on the Android dependency
103-
compileOnly("software.amazon.awssdk.crt:aws-crt:$crtJavaVersion")
99+
compileOnly(libs.crt.java)
100+
val crtJavaVersion = libs.versions.crt.java.version.get()
104101
implementation("software.amazon.awssdk.crt:aws-crt-android:$crtJavaVersion@aar")
105102

106103
// FIXME - temporary integration with CompletableFuture while we work out a POC on the jvm target
107-
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-jdk8:$coroutinesVersion")
104+
implementation(libs.kotlinx.coroutines.jdk8)
108105
}
109106
}
110107

aws-crt-kotlin/common/test/aws/sdk/kotlin/crt/http/HttpClientConnectionTest.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,6 @@ import aws.sdk.kotlin.crt.runSuspendTest
1111
import aws.sdk.kotlin.crt.use
1212
import kotlinx.coroutines.withTimeout
1313
import kotlin.test.*
14-
import kotlin.time.ExperimentalTime
1514
import kotlin.time.measureTime
1615

1716
class HttpClientConnectionTest : CrtTest() {

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/CRTNative.kt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,7 @@
1+
/*
2+
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
3+
* SPDX-License-Identifier: Apache-2.0
4+
*/
15
package aws.sdk.kotlin.crt
26

37
public actual object CRT {

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/auth/credentials/CachedCredentialsProviderNative.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55

66
package aws.sdk.kotlin.crt.auth.credentials
77

8-
98
public actual class CachedCredentialsProvider internal actual constructor(builder: CachedCredentialsProviderBuilder) :
109
CredentialsProvider {
1110
public actual companion object {}

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/auth/credentials/DefaultChainCredentialsProviderNative.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,5 +20,4 @@ public actual class DefaultChainCredentialsProvider internal actual constructor(
2020
override suspend fun waitForShutdown() {
2121
TODO("Not yet implemented")
2222
}
23-
2423
}

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/auth/credentials/EcsCredentialsProviderNative.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,4 @@ internal actual constructor(builder: EcsCredentialsProviderBuilder) :
2121
override suspend fun waitForShutdown() {
2222
TODO("Not yet implemented")
2323
}
24-
2524
}

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/auth/credentials/StaticCredentialsProviderNative.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,5 +23,4 @@ public actual class StaticCredentialsProvider internal actual constructor(builde
2323
override suspend fun waitForShutdown() {
2424
TODO("Not yet implemented")
2525
}
26-
2726
}

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/auth/signing/AwsSignerNative.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,5 +40,4 @@ public actual object AwsSigner {
4040
): AwsSigningResult {
4141
TODO("Not yet implemented")
4242
}
43-
44-
}
43+
}

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/http/HttpClientConnectionManagerNative.kt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,4 @@ public actual class HttpClientConnectionManager actual constructor(
3232
override fun close() {
3333
TODO("Not yet implemented")
3434
}
35-
36-
}
35+
}

aws-crt-kotlin/native/src/aws/sdk/kotlin/crt/io/EventLoopGroupNative.kt

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,4 @@ public actual class EventLoopGroup actual constructor(maxThreads: Int) : Closeab
2424
override fun close() {
2525
TODO("Not yet implemented")
2626
}
27-
2827
}

0 commit comments

Comments
 (0)