Eureka Bean Springboot 3

134 Views Asked by At

My server eureka is up. but My application can't work because i have an error *Failed to start bean 'eurekaAutoServiceRegistration'*

Hi, My environment is

Java 17 and Springboot 3.2.1

i launch my eureka server on the port 9102. But when i launch my application i get an error message

Caused by: java.lang.NullPointerException: Cannot invoke "org.springframework.cloud.netflix.eureka.CloudEurekaClient.getApplications()" because the return value of "org.springframework.cloud.netflix.eureka.serviceregistry.EurekaRegistration.getEurekaClient()" is null
    at org.springframework.cloud.netflix.eureka.serviceregistry.EurekaServiceRegistry.maybeInitializeClient(EurekaServiceRegistry.java:54) ~[spring-cloud-netflix-eureka-client-4.1.0.jar:4.1.0]
    at org.springframework.cloud.netflix.eureka.serviceregistry.EurekaServiceRegistry.register(EurekaServiceRegistry.java:38) ~[spring-cloud-netflix-eureka-client-4.1.0.jar:4.1.0]
    at org.springframework.cloud.netflix.eureka.serviceregistry.EurekaAutoServiceRegistration.start(EurekaAutoServiceRegistration.java:83) ~[spring-cloud-netflix-eureka-client-4.1.0.jar:4.1.0]
    at org.springframework.context.support.DefaultLifecycleProcessor.doStart(DefaultLifecycleProcessor.java:284) ~[spring-context-6.1.2.jar:6.1.2]
    ... 13 common frames omitted

my config is :

eureka.client.serviceUrl.defaultZone=http://localhost:9102/eureka/

Can you help me?

0

There are 0 best solutions below