From b0b1c04fc4c56deb44d100335e45cd997c1d376a Mon Sep 17 00:00:00 2001 From: Shannon Carey Date: Tue, 13 Apr 2021 14:58:26 -0500 Subject: [PATCH 1/2] Document spring.config.additional-location should be used early See gh-26085 --- .../src/docs/asciidoc/spring-boot-features.adoc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc index 8153b27363..40f9231409 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc @@ -630,7 +630,8 @@ The following example shows how to specify two locations: TIP: Use the prefix `optional:` if the <> and you don't mind if they don't exist. -WARNING: `spring.config.name` and `spring.config.location` are used very early to determine which files have to be loaded. +WARNING: `spring.config.name`, `spring.config.location`, and `spring.config.additional-location` are used very early to +determine which files have to be loaded. They must be defined as an environment property (typically an OS environment variable, a system property, or a command-line argument). If `spring.config.location` contains directories (as opposed to files), they should end in `/` (at runtime they will be appended with the names generated from `spring.config.name` before being loaded). From 1855f96d077e07996584b41bf5ad3718a8c92cd0 Mon Sep 17 00:00:00 2001 From: Stephane Nicoll Date: Wed, 14 Apr 2021 10:06:06 +0200 Subject: [PATCH 2/2] Polish "Document spring.config.additional-location should be used early" See gh-26085 --- .../src/docs/asciidoc/spring-boot-features.adoc | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc index 40f9231409..083304fc11 100644 --- a/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc +++ b/spring-boot-project/spring-boot-docs/src/docs/asciidoc/spring-boot-features.adoc @@ -630,8 +630,7 @@ The following example shows how to specify two locations: TIP: Use the prefix `optional:` if the <> and you don't mind if they don't exist. -WARNING: `spring.config.name`, `spring.config.location`, and `spring.config.additional-location` are used very early to -determine which files have to be loaded. +WARNING: `spring.config.name`, `spring.config.location`, and `spring.config.additional-location` are used very early to determine which files have to be loaded. They must be defined as an environment property (typically an OS environment variable, a system property, or a command-line argument). If `spring.config.location` contains directories (as opposed to files), they should end in `/` (at runtime they will be appended with the names generated from `spring.config.name` before being loaded).