Spring boot fits with microservices, facilitates rapid development, simplifies configuration (contract > configuration). Preparatory work:
- Springboot 2.0
- Jdk8
- Idea or eclipse+spring Tool suits
Create a project What did not say, see link: http://tengj.top/2017/02/26/springboot1/Note:
Springboot default profile read by default is iso8859-1, this time the input of Chinese will be automatically encoded, if changed to UTF-8 can be displayed normally, but spring read according to ISO is garbled.
Solution: Idea of Baidu, Eclipse temporarily no solution.
Replace properties for YML,YML support direct use of UTF-8 encoding, and easier to read
Workaround: Replace the suffix name directly
Attached: yml format red circle Live
Tomcat Thermal Deployment issues
Configure MAVEN to update resources without restarting the project
<!--Hot Swapping, disable cache for template, enable live reload - <Dependency> <groupId>Org.springframework.boot</groupId> <Artifactid>Spring-boot-devtools</Artifactid> <Optional>True</Optional> </Dependency>
Appendix: Other people write good documents, very good http://tengj.top/tags/Spring-Boot/
Spring Boot (i) Hello world