From 2948027551663dd735cd5d8f9b5ddf004db58c16 Mon Sep 17 00:00:00 2001 From: wrongwrong Date: Sun, 19 Nov 2023 01:34:15 +0900 Subject: [PATCH] Fixed sample code for KotlinModule initialization. Initialization using the constructor has been deprecated. --- docs/src/main/asciidoc/kotlin.adoc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/docs/src/main/asciidoc/kotlin.adoc b/docs/src/main/asciidoc/kotlin.adoc index ef117f0c8d0fb..0d7bc89658eb4 100644 --- a/docs/src/main/asciidoc/kotlin.adoc +++ b/docs/src/main/asciidoc/kotlin.adoc @@ -470,9 +470,9 @@ import io.fabric8.kubernetes.client.utils.Serialization import com.fasterxml.jackson.module.kotlin.KotlinModule ... - -Serialization.jsonMapper().registerModule(KotlinModule()) -Serialization.yamlMapper().registerModule(KotlinModule()) +val kotlinModule = KotlinModule.Builder().build() +Serialization.jsonMapper().registerModule(kotlinModule) +Serialization.yamlMapper().registerModule(kotlinModule) ---- _Please test this carefully on compilation to native images and fallback to Java-compatible Jackson bindings if you experience problems._