1.报错
启动第一个服务时是ok的,当修改端口在此启动,发现第一个会挂掉,不能同时启动多个。
***************************
APPLICATION FAILED TO START
***************************
Description:
The Tomcat connector configured to listen on port 8862 failed to start. The port may already be in use or the connector may be misconfigured.
Action:
Verify the connector's configuration, identify and stop any process that's listening on port 8862, or configure this application to listen on another port.
2.原因
负载的时候,不能添加热启动依赖。
<!--热启动-->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-devtools</artifactId>
</dependency>
3.解决方案
去掉热启动依赖就ok