This release contains all of the changes from 1.7.0-RC and is compatible with Kotlin 2.0.
Please note that for reasons explained in the 1.7.0-RC changelog, it may not be possible to use it with the Kotlin 1.9.x
compiler plugin. Yet, it is still fully backward compatible with previous versions.
The only difference with 1.7.0-RC is that the classDiscriminatorMode property in JsonBuilder is marked as experimental,
as it should have been when it was introduced (#2680).
1.7.0-RC
This is a release candidate for the next version. It is based on Kotlin 2.0.0-RC3 and is fully compatible with a stable Kotlin 2.0 release.
Due to a potential breaking change (see below), it requires a compiler plugin with a version at least of 2.0.0-RC1.
Important change: priority of PolymorphicSerializer for interfaces during call to serializer() function
Non-sealed interfaces in kotlinx.serialization are always serializable with a polymorphic serializer,
even if they do not have @Serializable annotation. This also means that serializersModule.serializer<SomeInterface>() call will return you a serializer capable of polymorphism. This function was written in a way that it unconditionally returns a PolymorphicSerializer if type argument is a non-sealed interface. This caused problems with SerializersModule functionality, because actual module was not taken into consideration, and therefore it was impossible to override serializer for interface using 'contextual serialization' feature. The problem is described in detail here. To overcome these problems, we had to change the behavior of this function regarding interfaces. It now looks into SerializersModule first if T is a non-sealed interface, and only if there is no registered contextual serializer for T, it returns a polymorphic serializer.
Behavior before 1.7.0-RC:
interface SomeInterface
val module = SerializersModule {
contextual(SomeInterface::class, CustomSomeInterfaceSerializer)
}
// Prints PolymorphicSerializer<SomeInterface>:
println(module.serializer<SomeInterface>())
Behavior in 1.7.0-RC, 1.7.0, and higher:
interface SomeInterface
val module = SerializersModule {
contextual(SomeInterface::class, CustomSomeInterfaceSerializer)
}
// Prints CustomSomeInterfaceSerializer:
println(module.serializer<SomeInterface>())
We expect minimal impact from this change, but be aware of it anyway.
Implementation details are available in this PR.
Due to the serializer() function being also a compiler intrinsic, code
of kotlinx.serialization compiler plugin also accommodates this change in the 2.0 branch. To get a consistent result from both plugin and runtime, kotlinx.serialization compiler plugin should be at least of 2.0.0-RC1 version.To verify so, 1.7.0-RC runtime will be rejected by older plugins.
This release contains all of the changes from 1.7.0-RC and is compatible with Kotlin 2.0.
Please note that for reasons explained in the 1.7.0-RC changelog, it may not be possible to use it with the Kotlin 1.9.x
compiler plugin. Yet, it is still fully backwards compatible with previous versions.
The only difference with 1.7.0-RC is that classDiscriminatorMode property in JsonBuilder is marked as experimental,
as it should have been when it was introduced (#2680).
1.7.0-RC / 2024-05-16
This is a release candidate for the next version. It is based on Kotlin 2.0.0-RC3 and is fully compatible with a stable Kotlin 2.0 release.
Due to a potential breaking change (see below), it requires a compiler plugin with a version at least of 2.0.0-RC1.
Important change: priority of PolymorphicSerializer for interfaces during call to serializer() function
Non-sealed interfaces in kotlinx.serialization are always serializable with a polymorphic serializer,
even if they do not have @Serializable annotation. This also means that serializersModule.serializer<SomeInterface>() call will return you a serializer capable of polymorphism.
This function was written in a way that it unconditionally returns a PolymorphicSerializer if type argument is a non-sealed interface.
This caused problems with SerializersModule functionality, because actual module was not taken into consideration, and therefore it was impossible
to override serializer for interface using 'contextual serialization' feature. The problem is described in details here.
To overcome these problems, we had to change the behavior of this function regarding interfaces. It now looks into SerializersModule first if T is a non-sealed interface,
and only if there is no registered contextual serializer for T, it returns a polymorphic serializer.
Behavior before 1.7.0-RC:
interface SomeInterface
val module = SerializersModule {
contextual(SomeInterface::class, CustomSomeInterfaceSerializer)
}
// Prints PolymorphicSerializer<SomeInterface>:
println(module.serializer<SomeInterface>())
Behavior in 1.7.0-RC, 1.7.0, and higher:
interface SomeInterface
val module = SerializersModule {
contextual(SomeInterface::class, CustomSomeInterfaceSerializer)
}
// Prints CustomSomeInterfaceSerializer:
println(module.serializer<SomeInterface>())
</tr></table>
... (truncated)
Commits
d2dc7d2 Update to Kotlin 2.0 and prepare 1.7.0 release (#2706)
1cac162 Merge remote-tracking branch 'origin/master' into dev
fbd0734 Use @PublishedApi annotation on functions called from plugin-generated code (...
4bf4113 Add bencoding to community-supported formats (#2687)
c487e78 JSON: Fix mutable classDiscriminatorMode in config, and mark experimental i...
BREAKING: Refactor ExtendedTracer, ExtendedSpanBuilder to reflect incubating API conventions (#6497)
SDK
Exporter
BREAKING: Serve prometheus metrics only on /metrics by default. To restore the previous behavior and serve metrics on all paths, override the default handler as demonstrated here. (#6476)
BREAKING: Refactor ExtendedTracer, ExtendedSpanBuilder to reflect incubating API conventions
(#6497)
SDK
Exporter
BREAKING: Serve prometheus metrics only on /metrics by default. To restore the previous behavior
and serve metrics on all paths, override the default handler
as demonstrated here.
(#6476)
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency
- `@dependabot ignore major version` will close this group update PR and stop Dependabot creating any more for the specific dependency's major version (unless you unignore this specific dependency's major version or upgrade to it yourself)
- `@dependabot ignore minor version` will close this group update PR and stop Dependabot creating any more for the specific dependency's minor version (unless you unignore this specific dependency's minor version or upgrade to it yourself)
- `@dependabot ignore ` will close this group update PR and stop Dependabot creating any more for the specific dependency (unless you unignore this specific dependency or upgrade to it yourself)
- `@dependabot unignore ` will remove all of the ignore conditions of the specified dependency
- `@dependabot unignore ` will remove the ignore condition of the specified dependency and ignore conditions
Bumps the minor-patch group with 4 updates in the / directory: org.jetbrains.kotlinx:kotlinx-serialization-json, io.opentelemetry:opentelemetry-bom, io.kotest:kotest-runner-junit5 and software.amazon.awscdk:aws-cdk-lib.
Updates
org.jetbrains.kotlinx:kotlinx-serialization-json
from 1.6.3 to 1.7.0Release notes
Sourced from org.jetbrains.kotlinx:kotlinx-serialization-json's releases.
... (truncated)
Changelog
Sourced from org.jetbrains.kotlinx:kotlinx-serialization-json's changelog.
... (truncated)
Commits
d2dc7d2
Update to Kotlin 2.0 and prepare 1.7.0 release (#2706)1cac162
Merge remote-tracking branch 'origin/master' into devfbd0734
Use@PublishedApi
annotation on functions called from plugin-generated code (...4bf4113
Add bencoding to community-supported formats (#2687)c487e78
JSON: Fix mutableclassDiscriminatorMode
in config, and mark experimental i...385c97d
Remove yellow code (#2691)688f64b
Added link to kotlinx-serialization-smile in the formats list (#2689)1f38e22
Add additional repositorydd1b76e
Prepare Changelog and Readme for 1.7.0-RC releaseb4bf182
Raise Require-Kotlin-Version to 2.0.0-RC1Updates
io.opentelemetry:opentelemetry-bom
from 1.38.0 to 1.39.0Release notes
Sourced from io.opentelemetry:opentelemetry-bom's releases.
Changelog
Sourced from io.opentelemetry:opentelemetry-bom's changelog.
Commits
96bb3ba
[release/v1.39.x] Prepare release 1.39.0 (#6508)edbb475
Prepare 1.39.0 (#6506)934da84
Fix incubator docs (#6505)d0b463d
Refactor ExtendedTracer, ExtendedSpanBuilder to reflect incubating API conven...7364687
Update dependency net.ltgt.gradle:gradle-errorprone-plugin to v4 (#6501)5a84398
Update dependency org.jctools:jctools-core to v4.0.5 (#6500)a68349e
Update errorProneVersion to v2.28.0 (#6489)e15eedc
Update dependency com.google.api.grpc:proto-google-common-protos to v2.40.0 (...88be482
Update dependency gradle to v8.8 (#6488)915cb4d
Update dependency com.uber.nullaway:nullaway to v0.11.0 (#6487)Updates
io.kotest:kotest-runner-junit5
from 5.9.0 to 5.9.1Release notes
Sourced from io.kotest:kotest-runner-junit5's releases.
... (truncated)
Commits
2cd159d
Add aninfix
variant ofshouldNotBeNull
that accepts a block (#4060)77cf524
Add simplified overloads to shouldMatchEach extensions (#3911) (#3929)9b00d42
Add Stacktrace Substring Matching to Throwable Matchers (#3998)2d3cbb6
Updated blogs list3452bc1
Fix test name comparison in docs (#4034)00a0b4e
singleElement-with-predicate-more-info (#3986)ed663eb
Refactor team city listener to extract the writing methods (#4053)97de2a1
fix retry ignore subclass of exception class (#3955)c3bb0fc
Add link to write-up about ranges (#4042)cb0a4a9
[Chore] Upgrade to the Develocity plugin to remove build warnings (#4045)Updates
software.amazon.awscdk:aws-cdk-lib
from 2.144.0 to 2.146.0Release notes
Sourced from software.amazon.awscdk:aws-cdk-lib's releases.
Changelog
Sourced from software.amazon.awscdk:aws-cdk-lib's changelog.
Commits
b368c78
chore(release): 2.146.0 (#30548)8d26820
chore: update changelog938ca00
chore(release): 2.146.0b14f3c9
chore: npm-check-updates && yarn upgrade (#30532)f1dc142
feat(appsync): addmaxBatchSize
property to theAppSyncFunction
Construct...f45f2ca
feat(eks): support AccessConfig for the Cluster construct (#30016)87e27e6
chore: add new team memberIanKonlog
(#30535)db3e77d
feat(opensearch): add OpenSearch 2.13 engine version (#30399)69c5dde
feat: implement node runtime region awareness for cdk vended custom resources...634d67d
chore: upgrade jsii to~5.4.21
(#30518)Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show