Spring Boot 2.X combat tutorial (10) Developer Tools

10. SpringApplication

SpringApplication class provides a convenient way of guiding the beginning Spring application main () method.

10 .1 failed to start

If your application can not be started, for example, if you start on port Web application 8080 and the port is already in use, you should see something similar to the following message:

***************************

APPLICATION FAILED TO START

***************************

 

Description:

 

Embedded servlet container failed to start. Port 8080 was already in use.

 

Action:

 

Identify and stop the process that's listening on port 8080 or configure this application to listen on another port.

 

To do this, we need to

org.springframework.boot.autoconfigure.logging.conditionEvaluationReportLoggingListener

Enable debug property or enable DEBUG logging.

For example, if you run the application using the Java -jar , you can debug enable the property as follows:

$ java -jar myproject-0.0.1-SNAPSHOT.jar --debug

10 .2 custom banner

By the banner.txt add files or the class path spring.banner.location banner printing when to change the startup property to the location of such documents.

Banners can http://patorjk.com/software/taag/ free production sites.

 

If in doubt, watch the video: https://ke.qq.com/course/428845

 

Guess you like

Origin www.cnblogs.com/daqiang123/p/11265748.html