Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Spring Cloud Eureka with Config Server

What is the recommended configuration when running both Config Server with Eureka Server? Should Config Server be a client of Eureka? Or should Eureka be dependent on Config Server properties for its configuration? Or is both OK?

like image 706
Turar Avatar asked Nov 13 '15 19:11

Turar


People also ask

What is Eureka config server?

Eureka Server is an application that holds the information about all client-service applications. Every Micro service will register into the Eureka server and Eureka server knows all the client applications running on each port and IP address. Eureka Server is also known as Discovery Server.

When should I use spring cloud config server?

Spring Cloud Config is Spring's client/server approach for storing and serving distributed configurations across multiple applications and environments. This configuration store is ideally versioned under Git version control and can be modified at application runtime.

What is spring cloud config server?

Spring Cloud Config provides server and client-side support for externalized configuration in a distributed system. With the Config Server you have a central place to manage external properties for applications across all environments.

How do I enable Eureka client in Spring Cloud config?

Register the Config Server with the annotation @EnableEurekaClient (it should be Auto Configured to register with Eureka already though) Show activity on this post. The Spring Cloud Config service provides configuration info for various other microservices, of which the Eureka service is one.

How do I include Eureka server in my project?

To include Eureka Server in your project, use the starter with a group ID of org.springframework.cloudand an artifact ID of spring-cloud-starter-netflix-eureka-server. See the Spring Cloud Project pagefor details on setting up your build system with the current Spring Cloud Release Train. Note

Should Eureka be dependent on config server properties for configuration?

Or should Eureka be dependent on Config Server properties for its configuration? Or is both OK? Show activity on this post. The default way to use Eureka and Config Server is to use Config First bootstrap. Essentially, you make eureka server a client of the config server but you don't make the config server a client of eureka.

What is Spring Cloud config?

What is Spring Cloud Config ?Need for it? Spring Cloud Config provides server and client-side support for externalized configuration in a distributed system. With the Config Server you have a central place to manage external properties for applications across all environments.


1 Answers

The default way to use Eureka and Config Server is to use Config First bootstrap. Essentially, you make eureka server a client of the config server but you don't make the config server a client of eureka.

As said by David Syer on these (and this) issues, the founder of spring cloud, you have to use the config server with a front end load balancer, so a single URL is already highly available.

I'm also a newbie in Spring Cloud but I agree with him since Eureka is a Service Discovery, IMHO it should function on it's problem domain only. It would make a complicated logic for Eureka servers who are asking the Config servers for it's configuration. I can't imagine how the Eureka Server would know which config server to get if the Config Server is also the Server of Eureka to get its list of defaultZone.

It would be much more simpler for me to separate the Config Server's HA.

like image 55
Jade Devin Nocum Cabatlao Avatar answered Oct 25 '22 19:10

Jade Devin Nocum Cabatlao