I am running my jar in the following way in unix
java -jar $classpath --spring.config.location=application.yml
And I am also using a properties file which I am configuring the following way:
@PropertySource("file:${DATASERVICE_PROPERTIES}")
Both application.yml and DATASERVICE_PROPERTIES have property
server.port
I want to use the server.port in application.yml.
I thought properties supplied via commandline has highest precedence(from below link), so why is server.port from DATASERVICE_PROPERTIES taken?