spring boot configuration file properties and YAML Comments
The configuration information acquisition properties and values.
1: application.properties configuration file to add:
Directly create the prompts to create.
How references the value in the program?
Browser access:
We can see the value of output.
Description:
Application priority attribute configuration file
2: Modify Port
Directly in application.properties in:
server.port=8888
After saving, spring boot will automatically help us restart.
We can see the port after the restart it was 8888.
3: Date format:
In the previous lesson when we visited saveuser:
Create a time stamp. We need to be modified to normal.
Contact Kaige:
Kaige Java (kaigejava)
Personal blog: www.kaigejava.com
How to configure?
Or add application.properties file:
spring.jackson.date-format = format time.
As shown below:
After the setup is complete, access:
Date format normal.