I was also having the same problem as you mentioned and it seems using index form on application.properties
was not working for me either.
To solve the problem I did something like below
some.server.url = url1, url2
Then to get the those properties I simply use @Value
@Value("${some.server.url}")
private String[] urls ;
Spring automatically splits the String with comma and return you an Array. AFAIK this was introduced in Spring 4+
If you don't want comma (,)
as seperator you have to use SpEL like below.
@Value("#{'${some.server.url}'.split(',')}")
private List<String> urls;
where split()
accepts the seperator