I have a property present in application.yml but the value of that property is present in another file. Over here username is present in file /etc/app/db_username
database:
url: localhost:14482
username: /etc/app/db_username
password: /etc/app/db_password
Is there a way I can have values of username and password from the file automatically instead of me reading the file.
@Value("${database.username}")
String username; //Will give me /etc/app/db_username
@Value("${database.password}")
String password; //Will give me /etc/app/db_password