Skip to Content
Hands-On Microservices with Spring Boot and Spring Cloud
book

Hands-On Microservices with Spring Boot and Spring Cloud

by Magnus Larsson
September 2019
Intermediate to advanced
668 pages
15h 59m
English
Packt Publishing
Content preview from Hands-On Microservices with Spring Boot and Spring Cloud

Configuring clients to the Eureka server

To be able to connect to the Eureka server, the microservices have the following configuration:

eureka:  client:    serviceUrl: defaultZone: http://localhost:8761/eureka/ initialInstanceInfoReplicationIntervalSeconds: 5 registryFetchIntervalSeconds: 5 instance: leaseRenewalIntervalInSeconds: 5 leaseExpirationDurationInSeconds: 5---spring.profiles: dockereureka.client.serviceUrl.defaultZone: http://eureka:8761/eureka/

The eureka.client.serviceUrl.defaultZone parameter is used to find the Eureka server, whereas the other parameters are used to minimize the startup time and the time it takes to deregister a microservice instance that is stopped.

The product-composite microservice, which uses the Eureka server ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Master Microservices with Spring Boot and Spring Cloud

Master Microservices with Spring Boot and Spring Cloud

In28Minutes Official

Publisher Resources

ISBN: 9781789613476Supplemental Content