環境:
IDEA
maven3.0
springboot2.2.0
特別注意springboot的版本,1.0和2.0有很大區別
解決辦法:
pom添加:
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
<version>2.1.1.RELEASE</version>
</dependency>