I have an embedded application.yml which includes 2 profile sections (profile1 and profile2). I also am using a config server which services an application.yml (with 2 profile sections) and. a service.yml (with 2 profile sections) and a service-profile1.yml.
The above files are read in this order:
- Embedded application.yml (non-profile section)
- Config Server application.yml (non-profile section)
- Config Server application.yml (profile1)
- Config Server application,yml (profile2)
- Config Server service.yml (non-profile section)
- Config Server service.yml (profile1)
- Config Server service..yml (profile2)
- Embedded application.yml (profile1)
- Embedded application.yml (profile2)
- Config Servere service-profile1.yml
So the processing of files from the Config Server reads all sections within a file when that file is processed. However, the processing of the embedded applicaiton.yml was split where profile sections were read after the Config Server (application.yml and service.yml) files were read.
For consistency, I would have expected the embedded application.yml, including all profile sections) to have been read before processing any files from the Config Server. So steps 8. & 9 above, they would move after step 1.
Comment From: philwebb
This may be related to #26593 and https://github.com/spring-cloud/spring-cloud-config/issues/1895.
@KJoyner could you please provide a sample application that shows the problem?
Comment From: spring-projects-issues
If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.
Comment From: spring-projects-issues
Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.