Skip to content

Commit d06079d

Browse files
committed
External Config Doc Update
This patch makes a small change to the documentation for External Configuration regarding how @value behaves with camelCase variables and environment variables.
1 parent 5922311 commit d06079d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

documentation/spring-boot-docs/src/docs/antora/modules/reference/pages/features/external-config.adoc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1380,7 +1380,7 @@ If you do want to use javadoc:org.springframework.beans.factory.annotation.Value
13801380
This will allow Spring Boot to use the same logic as it does when xref:features/external-config.adoc#features.external-config.typesafe-configuration-properties.relaxed-binding[relaxed binding] javadoc:org.springframework.boot.context.properties.ConfigurationProperties[format=annotation].
13811381
13821382
For example, `@Value("${demo.item-price}")` will pick up `demo.item-price` and `demo.itemPrice` forms from the `application.properties` file, as well as `DEMO_ITEMPRICE` from the system environment.
1383-
If you used `@Value("${demo.itemPrice}")` instead, `demo.item-price` and `DEMO_ITEMPRICE` would not be considered.
1383+
If you used `@Value("${demo.itemPrice}")` instead, `demo.item-price` would not be considered; however, `DEMO_ITEMPRICE` from the environment would still be considered.
13841384
====
13851385

13861386
If you define a set of configuration keys for your own components, we recommend you group them in a POJO annotated with javadoc:org.springframework.boot.context.properties.ConfigurationProperties[format=annotation].

0 commit comments

Comments
 (0)