使用spring boot 2.0.0.RELEASE无法执行简单的spring boot管理服务器

时间:2018-04-03 13:40:13

标签: spring-boot spring-boot-admin

的pom.xml

<parent>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-parent</artifactId>
    <version>2.0.0.RELEASE</version>
    <relativePath /> <!-- lookup parent from repository -->
</parent>


<dependencies>
<dependency>
    <groupId>org.springframework.boot</groupId>
    <artifactId>spring-boot-starter-web</artifactId>
</dependency>

<dependency>
    <groupId>de.codecentric</groupId>
    <artifactId>spring-boot-admin-server</artifactId>
    <version>1.5.4</version>
</dependency>

<dependency>
    <groupId>de.codecentric</groupId>
    <artifactId>spring-boot-admin-server-ui</artifactId>
    <version>1.5.4</version>
</dependency>

@EnableAdminServer
@SpringBootApplication
public class SpringBootAdminApplication {
    public static void main(String[] args) {
        SpringApplication.run(SpringBootAdminApplication.class, args);
    }
}
  

执行spring boot服务器时给出错误:任何类型的帮助都将被赞赏......

     

error java.lang.NoSuchMethodError:org.springframework.boot.builder.SpringApplicationBuilder。([Ljava / lang / Object;)V

1 个答案:

答案 0 :(得分:2)

Spring Boot Admin尚不支持Spring Boot 2.0.0。请参阅:https://github.com/codecentric/spring-boot-admin/issues/668

如果你想使用spring boot admin,你应该使用旧版本的spring boot。