spring-boot icon indicating copy to clipboard operation
spring-boot copied to clipboard

Add @DynamicPropertySource to documented list of property source ordering

Open altery opened this issue 3 years ago • 0 comments

The Boot Documentation has a section about PropertySource order. The @DynamicPropertySource is missing in this list. According to its JavaDoc, @DynamicPropertySource would be after @TestPropertySource, though it is unclear, if it has higher priority than Devtools global settings.

Dynamic properties have higher precedence than those loaded from @TestPropertySource, the operating system's environment, Java system properties, or property sources added by the application declaratively by using @PropertySource or programmatically. Thus, dynamic properties can be used to selectively override properties loaded via @TestPropertySource, system property sources, and application property sources.

altery avatar Oct 27 '22 07:10 altery