[Spring boot] Application properties and configurations

We can use different application properties

[Spring boot] Application properties and configurations

application.properties:

server.port=9090

application-prod.properties:

server.port=80

application-test.properties:

server.port=9090

We can setup different properties for different env, more about configration can be found here

Run:

-Dspring.profiles.active=test

WIll run test env:

[Spring boot] Application properties and configurations

上一篇:洛谷P1776 宝物筛选


下一篇:也用 Log4Net 之将自定义属性记录到文件中 (三)