I have property file application-dev.yml with content:
spring.profiles: dev
config.some.value:
- ELEMENT1
- ELEMENT2
and another application-staging.yml with content:
spring.profiles: staging
config.some.value:
- ELEMENT1
- ELEMENT2
- ELEMENT3
so I basically do not know size of list. When I reference this list in main application.yml like this:
some.value: ${config.some.value}
I get Failed to convert property value of type 'java.lang.String' to required type 'java.util.List' for property 'value'. How to reference it correctly?