From 1482b9a5899e02e2175a621d9c187c4d5bd1985a Mon Sep 17 00:00:00 2001 From: Weix Sun Date: Sun, 14 Nov 2021 14:50:38 +0800 Subject: [PATCH 1/2] Format the yaml configuration items correctly --- .../src/docs/asciidoc/features/external-config.adoc | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc index a308a85ae255..e570fedf5f3f 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc @@ -470,10 +470,16 @@ For example, the following file has two logical documents: [source,yaml,indent=0,subs="verbatim"] ---- - spring.application.name: MyApp + spring: + application: + name: "MyApp" --- - spring.config.activate.on-cloud-platform: kubernetes - spring.application.name: MyCloudApp + spring: + application: + name: "MyCloudApp" + config: + activate: + on-cloud-platform: kubernetes ---- For `application.properties` files a special `#---` comment is used to mark the document splits: From 16d71cc8573957130a8c7675347062a989ea7b18 Mon Sep 17 00:00:00 2001 From: Weix Sun Date: Sun, 14 Nov 2021 14:56:54 +0800 Subject: [PATCH 2/2] Sort the order of configuration items --- .../src/docs/asciidoc/features/external-config.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc index e570fedf5f3f..4da8b080bb26 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/features/external-config.adoc @@ -475,11 +475,11 @@ For example, the following file has two logical documents: name: "MyApp" --- spring: - application: - name: "MyCloudApp" config: activate: on-cloud-platform: kubernetes + application: + name: "MyCloudApp" ---- For `application.properties` files a special `#---` comment is used to mark the document splits: