Skip to content

Commit 79db641

Browse files
committed
update to Kotlin 1.8
Update Kotlin version to 1.8.22
1 parent 31c4e12 commit 79db641

File tree

77 files changed

+266
-286
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

77 files changed

+266
-286
lines changed

clients/graphql-kotlin-client-jackson/build.gradle.kts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ tasks {
1616
limit {
1717
counter = "INSTRUCTION"
1818
value = "COVEREDRATIO"
19-
minimum = "0.89".toBigDecimal()
19+
minimum = "0.85".toBigDecimal()
2020
}
2121
}
2222
}

gradle/libs.versions.toml

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,18 @@ federation = "3.0.1"
66
graphql-java = "20.2"
77
graalvm = "0.9.21"
88
jackson = "2.15.0"
9-
kotlin = "1.7.21"
10-
# TODO kotlin 1.8 upgrade -> kotlinx-benchmark 0.4.7+ uses kotlin 1.8
11-
kotlinx-benchmark = "0.4.6"
12-
# TODO kotlin 1.8 upgrade -> kotlinx-coroutines 1.7.0+ uses kotlin 1.8
13-
kotlinx-coroutines = "1.6.4"
14-
# TODO kotlin 1.8 upgrade -> kotlinx-serialization 1.5.0+ uses kotlin 1.8
15-
kotlinx-serialization = "1.4.1"
16-
# TODO kotlin 1.8 upgrade -> ktor 2.3.0+ uses kotlin 1.8
17-
ktor = "2.2.4"
9+
# kotlin version has to match the compile-testing compiler version
10+
kotlin = "1.8.22"
11+
# TODO kotlin 1.9 upgrade -> kotlinx-benchaamrk 0.4.9+ uses kotlin 1.9
12+
kotlinx-benchmark = "0.4.8"
13+
kotlinx-coroutines = "1.7.3"
14+
# TODO kotlin 1.9 upgrade -> kotlinx-serialization 1.6.0+ uses kotlin 1.9
15+
kotlinx-serialization = "1.5.1"
16+
ktor = "2.3.3"
1817
maven-plugin-annotation = "3.9.0"
1918
maven-plugin-api = "3.9.2"
2019
maven-project = "2.2.1"
21-
# TODO kotlin 1.8 upgrade -> kotlinpoet 1.13.0+ uses kotlin 1.8
22-
poet = "1.12.0"
20+
poet = "1.14.2"
2321
## reactor and spring versions should be the same as defined in spring-boot-dependencies
2422
reactor-core = "3.5.6"
2523
reactor-extensions = "1.2.2"
@@ -28,22 +26,18 @@ spring = "6.0.9"
2826
spring-boot = "3.1.0"
2927

3028
# test dependencies
31-
# kotlin-compile-testing has to be using the same kotlin version as the kotlinx-serialization compiler
32-
# https://github.com/tschuchortdev/kotlin-compile-testing the latest version targets kotlin 1.7.10 which blocks updates to newer
33-
# versions of kotlin, switching to a fork https://github.com/ZacSweers/kotlin-compile-testing
34-
compile-testing = "0.1.0"
29+
compile-testing = "0.3.2"
3530
icu = "73.1"
3631
junit = "5.9.3"
3732
logback = "1.4.7"
38-
# TODO kotlin 1.8 upgrade -> mock 1.13.4+ uses kotlin 1.8
39-
mockk = "1.13.3"
33+
mockk = "1.13.7"
4034
rxjava = "3.1.6"
4135
wiremock = "2.35.0"
4236

4337
# plugins
44-
# TODO kotlin 1.8 upgrade -> detekt 1.22.0+ uses kotlin 1.8
45-
detekt = "1.21.0"
46-
dokka = "1.7.20"
38+
# TODO kotlin 1.9 upgrade -> detekt 1.23.1+ uses kotlin 1.9
39+
detekt = "1.23.0"
40+
dokka = "1.8.20"
4741
jacoco = "0.8.10"
4842
# klint gradle plugin breaks with 0.46.x+
4943
ktlint-core = "0.45.2"
@@ -99,6 +93,8 @@ junit-api = { group = "org.junit.jupiter", name = "junit-jupiter-api", version.r
9993
junit-engine = { group = "org.junit.jupiter", name = "junit-jupiter-engine", version.ref = "junit" }
10094
junit-params = { group = "org.junit.jupiter", name = "junit-jupiter-params", version.ref = "junit" }
10195
kotlin-junit-test = { group = "org.jetbrains.kotlin", name = "kotlin-test-junit5", version.ref = "kotlin" }
96+
kotlin-annotation-processing = { group = "org.jetbrains.kotlin", name = "kotlin-annotation-processing-embeddable", version.ref = "kotlin" }
97+
kotlin-compiler = { group = "org.jetbrains.kotlin", name = "kotlin-compiler-embeddable", version.ref = "kotlin" }
10298
kotlin-test = { group = "org.jetbrains.kotlin", name = "kotlin-test", version.ref = "kotlin" }
10399
kotlinx-benchmark = { group = "org.jetbrains.kotlinx", name = "kotlinx-benchmark-runtime", version.ref = "kotlinx-benchmark" }
104100
kotlinx-coroutines-test = { group = "org.jetbrains.kotlinx", name = "kotlinx-coroutines-test", version.ref = "kotlinx-coroutines" }

plugins/client/graphql-kotlin-client-generator/build.gradle.kts

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,17 +14,25 @@ dependencies {
1414
implementation(libs.jackson)
1515
implementation(libs.ktor.client.apache)
1616
implementation(libs.ktor.serialization.jackson) {
17-
exclude("com.fasterxml.jackson.core", "jackson-databind")
18-
exclude("com.fasterxml.jackson.module", "jackson-module-kotlin")
17+
exclude(group = "com.fasterxml.jackson.core", module = "jackson-databind")
18+
exclude(group = "com.fasterxml.jackson.module", module = "jackson-module-kotlin")
1919
}
2020
implementation(libs.ktor.client.content)
2121
implementation(libs.slf4j)
2222
testImplementation(projects.graphqlKotlinClientJackson)
2323
testImplementation(projects.graphqlKotlinClientSerialization)
2424
testImplementation(libs.wiremock.jre8)
25-
testImplementation(libs.compile.testing)
25+
testImplementation(libs.compile.testing) {
26+
// there is no kotlin compile testing release supporting kotlin 1.8.22
27+
// explicitly downgrading kotlin version to match project version
28+
exclude(group = "org.jetbrains.kotlin", module = "kotlin-annotation-processing-embeddable")
29+
exclude(group = "org.jetbrains.kotlin", module = "kotlin-compiler-embeddable")
30+
}
2631
testImplementation(libs.icu)
2732
testImplementation(libs.junit.params)
33+
// compile testing workaround -> explicit dependencies for compiler/annotation-processing
34+
testImplementation(libs.kotlin.annotation.processing)
35+
testImplementation(libs.kotlin.compiler)
2836
testImplementation(libs.kotlin.serialization)
2937
}
3038

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/alias/AliasQuery.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ public const val ALIAS_QUERY: String =
1111

1212
@Generated
1313
public class AliasQuery : GraphQLClientRequest<AliasQuery.Result> {
14-
public override val query: String = ALIAS_QUERY
14+
override val query: String = ALIAS_QUERY
1515

16-
public override val operationName: String = "AliasQuery"
16+
override val operationName: String = "AliasQuery"
1717

18-
public override fun responseType(): KClass<AliasQuery.Result> = AliasQuery.Result::class
18+
override fun responseType(): KClass<AliasQuery.Result> = AliasQuery.Result::class
1919

2020
@Generated
2121
public data class Result(

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/alias_nested/AliasNestedQuery.kt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,12 +12,11 @@ public const val ALIAS_NESTED_QUERY: String =
1212

1313
@Generated
1414
public class AliasNestedQuery : GraphQLClientRequest<AliasNestedQuery.Result> {
15-
public override val query: String = ALIAS_NESTED_QUERY
15+
override val query: String = ALIAS_NESTED_QUERY
1616

17-
public override val operationName: String = "AliasNestedQuery"
17+
override val operationName: String = "AliasNestedQuery"
1818

19-
public override fun responseType(): KClass<AliasNestedQuery.Result> =
20-
AliasNestedQuery.Result::class
19+
override fun responseType(): KClass<AliasNestedQuery.Result> = AliasNestedQuery.Result::class
2120

2221
@Generated
2322
public data class Result(

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/documentation/DocumentationQuery.kt

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -11,12 +11,11 @@ public const val DOCUMENTATION_QUERY: String =
1111

1212
@Generated
1313
public class DocumentationQuery : GraphQLClientRequest<DocumentationQuery.Result> {
14-
public override val query: String = DOCUMENTATION_QUERY
14+
override val query: String = DOCUMENTATION_QUERY
1515

16-
public override val operationName: String = "DocumentationQuery"
16+
override val operationName: String = "DocumentationQuery"
1717

18-
public override fun responseType(): KClass<DocumentationQuery.Result> =
19-
DocumentationQuery.Result::class
18+
override fun responseType(): KClass<DocumentationQuery.Result> = DocumentationQuery.Result::class
2019

2120
@Generated
2221
public data class Result(

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/include_skip_directives/IncludeSkipDirectivesQuery.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -14,13 +14,13 @@ public const val INCLUDE_SKIP_DIRECTIVES_QUERY: String =
1414

1515
@Generated
1616
public class IncludeSkipDirectivesQuery(
17-
public override val variables: IncludeSkipDirectivesQuery.Variables,
17+
override val variables: IncludeSkipDirectivesQuery.Variables,
1818
) : GraphQLClientRequest<IncludeSkipDirectivesQuery.Result> {
19-
public override val query: String = INCLUDE_SKIP_DIRECTIVES_QUERY
19+
override val query: String = INCLUDE_SKIP_DIRECTIVES_QUERY
2020

21-
public override val operationName: String = "IncludeSkipDirectivesQuery"
21+
override val operationName: String = "IncludeSkipDirectivesQuery"
2222

23-
public override fun responseType(): KClass<IncludeSkipDirectivesQuery.Result> =
23+
override fun responseType(): KClass<IncludeSkipDirectivesQuery.Result> =
2424
IncludeSkipDirectivesQuery.Result::class
2525

2626
@Generated

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/input_hard_coded/HardCodedInputQuery.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,11 @@ public const val HARD_CODED_INPUT_QUERY: String =
1111

1212
@Generated
1313
public class HardCodedInputQuery : GraphQLClientRequest<HardCodedInputQuery.Result> {
14-
public override val query: String = HARD_CODED_INPUT_QUERY
14+
override val query: String = HARD_CODED_INPUT_QUERY
1515

16-
public override val operationName: String = "HardCodedInputQuery"
16+
override val operationName: String = "HardCodedInputQuery"
1717

18-
public override fun responseType(): KClass<HardCodedInputQuery.Result> =
18+
override fun responseType(): KClass<HardCodedInputQuery.Result> =
1919
HardCodedInputQuery.Result::class
2020

2121
@Generated

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/input_lists/InputListQuery.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,13 @@ public const val INPUT_LIST_QUERY: String =
1212

1313
@Generated
1414
public class InputListQuery(
15-
public override val variables: InputListQuery.Variables,
15+
override val variables: InputListQuery.Variables,
1616
) : GraphQLClientRequest<InputListQuery.Result> {
17-
public override val query: String = INPUT_LIST_QUERY
17+
override val query: String = INPUT_LIST_QUERY
1818

19-
public override val operationName: String = "InputListQuery"
19+
override val operationName: String = "InputListQuery"
2020

21-
public override fun responseType(): KClass<InputListQuery.Result> = InputListQuery.Result::class
21+
override fun responseType(): KClass<InputListQuery.Result> = InputListQuery.Result::class
2222

2323
@Generated
2424
public data class Variables(

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/input_self_reference/SelfReferencingInputQuery.kt

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,13 +13,13 @@ public const val SELF_REFERENCING_INPUT_QUERY: String =
1313

1414
@Generated
1515
public class SelfReferencingInputQuery(
16-
public override val variables: SelfReferencingInputQuery.Variables,
16+
override val variables: SelfReferencingInputQuery.Variables,
1717
) : GraphQLClientRequest<SelfReferencingInputQuery.Result> {
18-
public override val query: String = SELF_REFERENCING_INPUT_QUERY
18+
override val query: String = SELF_REFERENCING_INPUT_QUERY
1919

20-
public override val operationName: String = "SelfReferencingInputQuery"
20+
override val operationName: String = "SelfReferencingInputQuery"
2121

22-
public override fun responseType(): KClass<SelfReferencingInputQuery.Result> =
22+
override fun responseType(): KClass<SelfReferencingInputQuery.Result> =
2323
SelfReferencingInputQuery.Result::class
2424

2525
@Generated

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_diff_selection_sets/DifferentSelectionSetQuery.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ public const val DIFFERENT_SELECTION_SET_QUERY: String =
1212

1313
@Generated
1414
public class DifferentSelectionSetQuery : GraphQLClientRequest<DifferentSelectionSetQuery.Result> {
15-
public override val query: String = DIFFERENT_SELECTION_SET_QUERY
15+
override val query: String = DIFFERENT_SELECTION_SET_QUERY
1616

17-
public override val operationName: String = "DifferentSelectionSetQuery"
17+
override val operationName: String = "DifferentSelectionSetQuery"
1818

19-
public override fun responseType(): KClass<DifferentSelectionSetQuery.Result> =
19+
override fun responseType(): KClass<DifferentSelectionSetQuery.Result> =
2020
DifferentSelectionSetQuery.Result::class
2121

2222
@Generated

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_diff_selection_sets/differentselectionsetquery/BasicInterface.kt

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,11 @@ public data class FirstInterfaceImplementation(
4343
/**
4444
* Unique identifier of the first implementation
4545
*/
46-
public override val id: Int,
46+
override val id: Int,
4747
/**
4848
* Name of the first implementation
4949
*/
50-
public override val name: String,
50+
override val name: String,
5151
/**
5252
* Custom field integer value
5353
*/
@@ -62,11 +62,11 @@ public data class SecondInterfaceImplementation(
6262
/**
6363
* Unique identifier of the second implementation
6464
*/
65-
public override val id: Int,
65+
override val id: Int,
6666
/**
6767
* Name of the second implementation
6868
*/
69-
public override val name: String,
69+
override val name: String,
7070
/**
7171
* Custom field float value
7272
*/
@@ -82,9 +82,9 @@ public data class DefaultBasicInterfaceImplementation(
8282
/**
8383
* Unique identifier of an interface
8484
*/
85-
public override val id: Int,
85+
override val id: Int,
8686
/**
8787
* Name field
8888
*/
89-
public override val name: String,
89+
override val name: String,
9090
) : BasicInterface

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_diff_selection_sets/differentselectionsetquery/BasicInterface2.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public data class FirstInterfaceImplementation2(
3838
/**
3939
* Name of the first implementation
4040
*/
41-
public override val name: String,
41+
override val name: String,
4242
/**
4343
* Custom field integer value
4444
*/
@@ -53,7 +53,7 @@ public data class SecondInterfaceImplementation2(
5353
/**
5454
* Name of the second implementation
5555
*/
56-
public override val name: String,
56+
override val name: String,
5757
/**
5858
* Custom field float value
5959
*/
@@ -69,5 +69,5 @@ public data class DefaultBasicInterface2Implementation(
6969
/**
7070
* Name field
7171
*/
72-
public override val name: String,
72+
override val name: String,
7373
) : BasicInterface2

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_impl_diff_selection_sets/DifferentSelectionSetQuery.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ public const val DIFFERENT_SELECTION_SET_QUERY: String =
1212

1313
@Generated
1414
public class DifferentSelectionSetQuery : GraphQLClientRequest<DifferentSelectionSetQuery.Result> {
15-
public override val query: String = DIFFERENT_SELECTION_SET_QUERY
15+
override val query: String = DIFFERENT_SELECTION_SET_QUERY
1616

17-
public override val operationName: String = "DifferentSelectionSetQuery"
17+
override val operationName: String = "DifferentSelectionSetQuery"
1818

19-
public override fun responseType(): KClass<DifferentSelectionSetQuery.Result> =
19+
override fun responseType(): KClass<DifferentSelectionSetQuery.Result> =
2020
DifferentSelectionSetQuery.Result::class
2121

2222
@Generated

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_impl_diff_selection_sets/differentselectionsetquery/BasicInterface.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ public data class FirstInterfaceImplementation(
3737
/**
3838
* Unique identifier of the first implementation
3939
*/
40-
public override val id: Int,
40+
override val id: Int,
4141
/**
4242
* Custom field integer value
4343
*/
@@ -52,7 +52,7 @@ public data class SecondInterfaceImplementation(
5252
/**
5353
* Unique identifier of the second implementation
5454
*/
55-
public override val id: Int,
55+
override val id: Int,
5656
/**
5757
* Custom field float value
5858
*/
@@ -68,5 +68,5 @@ public data class DefaultBasicInterfaceImplementation(
6868
/**
6969
* Unique identifier of an interface
7070
*/
71-
public override val id: Int,
71+
override val id: Int,
7272
) : BasicInterface

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_impl_diff_selection_sets/differentselectionsetquery/BasicInterface2.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ public data class FirstInterfaceImplementation2(
3838
/**
3939
* Unique identifier of the first implementation
4040
*/
41-
public override val id: Int,
41+
override val id: Int,
4242
/**
4343
* Name of the first implementation
4444
*/
@@ -57,7 +57,7 @@ public data class SecondInterfaceImplementation2(
5757
/**
5858
* Unique identifier of the second implementation
5959
*/
60-
public override val id: Int,
60+
override val id: Int,
6161
/**
6262
* Name of the second implementation
6363
*/
@@ -77,5 +77,5 @@ public data class DefaultBasicInterface2Implementation(
7777
/**
7878
* Unique identifier of an interface
7979
*/
80-
public override val id: Int,
80+
override val id: Int,
8181
) : BasicInterface2

plugins/client/graphql-kotlin-client-generator/src/test/data/generator/interface_missing_types/InterfaceMissingTypeSelection.kt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@ public const val INTERFACE_MISSING_TYPE_SELECTION: String =
1212
@Generated
1313
public class InterfaceMissingTypeSelection :
1414
GraphQLClientRequest<InterfaceMissingTypeSelection.Result> {
15-
public override val query: String = INTERFACE_MISSING_TYPE_SELECTION
15+
override val query: String = INTERFACE_MISSING_TYPE_SELECTION
1616

17-
public override val operationName: String = "InterfaceMissingTypeSelection"
17+
override val operationName: String = "InterfaceMissingTypeSelection"
1818

19-
public override fun responseType(): KClass<InterfaceMissingTypeSelection.Result> =
19+
override fun responseType(): KClass<InterfaceMissingTypeSelection.Result> =
2020
InterfaceMissingTypeSelection.Result::class
2121

2222
@Generated

0 commit comments

Comments
 (0)