Creating profile-based property files
In the previous section, we realized the ability to extract certain aspects of our application into property files. The next big step you can take is realizing how far you can go with this.
Inevitably, we run into situations such as carrying our application into a new environment and wondering, “can we change the properties for THIS situation?”
For example, what if our application, before release, has to be installed in a test bed where it can get checked out? The databases are different. The test team may want a different set of test accounts. And any other external services (message brokers, authentication systems, and so on) will probably also be different.
So, the question arises, “can I have a different set of properties?” To which Spring Boot says “yes!”
To check this out, create another property file. Call it application-test.properties
and load it up, like this:
app.config.header...