Default properties are provided by Spring Boot’s SpringApplication.setDefaultProperties() method.
@PropertySource-annotated @Configuration classes.
Config data (such as application.properties files).
A RandomValuePropertySource that has properties only in random.*.
OS environment variables.
Java System properties (System.getProperties()).
JNDI attributes from java:comp/env.
ServletContext init parameters.
ServletConfig init parameters.
Properties from SPRING_APPLICATION_JSON (inline JSON embedded in an environment variable or system property).
Command-line arguments, as shown in the previous section.
properties attribute on your tests. Available with the @SpringBootTest annotation and also slice-based testing (which we covered back in Chapter 5, Testing with Spring Boot in the Testing data repositories with Testcontainers section)
@TestPropertySource annotations on your tests.
DevTools global settings properties (the $HOME/.config/spring-boot directory when Spring Boot DevTools is active).