required a bean of type ‘com.netflix.discovery.AbstractDiscoveryClientOptionalArgs‘ that could not b

Eureka 错误收集:

[ main] s.c.a.AnnotationConfigApplicationContext : Exception encountered during context initialization - cancelling refresh attempt: org.springframework.beans.factory.UnsatisfiedDependencyException: Error creating bean with name ‘org.springframework.cloud.netflix.eureka.EurekaClientAutoConfiguration$RefreshableEurekaClientConfiguration’: Unsatisfied dependency expressed through field ‘optionalArgs’; nested exception is org.springframework.beans.factory.NoSuchBeanDefinitionException: No qualifying bean of type ‘com.netflix.discovery.AbstractDiscoveryClientOptionalArgs<?>’ available: expected at least 1 bean which qualifies as autowire candidate. Dependency annotations: {@org.springframework.beans.factory.annotation.Autowired(required=true)}


APPLICATION FAILED TO START


Description:

Field optionalArgs in org.springframework.cloud.netflix.eureka.EurekaClientAutoConfiguration$RefreshableEurekaClientConfiguration required a bean of type ‘com.netflix.discovery.AbstractDiscoveryClientOptionalArgs’ that could not be found.

The injection point has the following annotations:
- @org.springframework.beans.factory.annotation.Autowired(required=true)

需要实现类bean:
在这里插入图片描述
检查需要引入了依赖: spring-boot-starter-web

posted @ 2021-10-05 21:30  IT当时语_青山师  阅读(63)  评论(0编辑  收藏  举报  来源