Reputation: 406
I getting following run time exceptions when i try to run my Springboot eureka client
org.springframework.beans.factory.BeanDefinitionStoreException: Failed to load bean class: ; nested exception is java.lang.IllegalStateException: Annotation @EnableDiscoveryClient found, but there are no implementations. Did you forget to include a starter?
Upvotes: 1
Views: 3045
Reputation: 1638
You should add the following starter POM to get all the required dependencies:
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-eureka</artifactId>
</dependency>
When not inheriting from SpringBoot parent POM, add the following in your <dependencyManagement>
:
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-dependencies</artifactId>
<version>${spring-boot.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
Upvotes: 3