Eureka netflix - cluster server list is empty
Asked Answered
A

1

9

I want to make service discovery without spring boot. So I have downloaded the netflix project example and because its gradle project I want to make it maven.

So i created maven project, imported the classes and configuration and i added dependency.

I placed the eureka.war in Tomcat webapps folder and i started the eureka server.

But when i run the application in eclipse i am getting an error.

ERROR c.netflix.discovery.DiscoveryClient - DiscoveryClient_UNKNOWN/DESKTOP-B997GFD - was unable to refresh its cache! status = There is no known eureka server; cluster server list is empty com.netflix.discovery.shared.transport.TransportException: There is no known eureka server; cluster server list is empty

and Cannot get an instance of example service to talk to from eureka

Amanuensis answered 22/9, 2017 at 10:26 Comment(0)
F
6

From log looks like Service name is not getting picked up from properties file and DiscoveryClient is looking for UNKNOWN

Got into similar error even while running it from gradle. Make sure host and port of eureka server is correct, most probably its correct if you have not changed any property. In my case I was connecting to our existing eureka.

eureka.region=us-east-2
eureka.us-east-2.availabilityZones=us-east-1a,us-east-1b,us-east-1c,us-east-1d
eureka.serviceUrl.us-east-1a=http://localhost:port/eureka/
eureka.serviceUrl.us-east-1b=http://localhost:port/eureka/

Below properties will help your Service to get register with eureka, keep it in file name eureka-client.properties

eureka.registration.enabled=true
eureka.name=sampleservice.mydomain.net
eureka.vipAddress=sampleservice.mydomain.net
Firm answered 5/9, 2018 at 6:32 Comment(1)
My question was 1 year ago and i closed that project. Thank you for your response maybe it will be helpful for someone else.Amanuensis

© 2022 - 2024 — McMap. All rights reserved.