How can you configure property sources in a specific order in Spring Boot for resolving properties?
- By using the spring.config.name property.
- By using the spring.config.order property.
- By setting the @PropertySource annotation order.
- By using the @ConfigurationProperties annotation order.
In Spring Boot, you can configure property sources in a specific order by using the spring.config.order property. This property allows you to specify the order in which configuration files are processed, with lower values indicating higher precedence. While other options are used in Spring Boot for property configuration, they do not control the order of property sources.
Loading...
Related Quiz
- To externalize configuration properties in Spring Boot, the _____ annotation can be used on a configuration properties class.
- In a Spring Boot application, the _____ annotation is used to bind the value of a method parameter to a named cookie value.
- For creating custom auto-configuration in Spring Boot, the configuration class needs to be listed in the _____ file.
- What is the role of the Init method in the Bean Lifecycle in Spring?
- What strategies would you employ to minimize the garbage collection pause times in a high-throughput Spring Boot application?