These are chat archives for spring-cloud/spring-cloud

Feb 2019
Patrick Gotthard
Feb 27 07:38

@marcosbarbero Thanks for your valuable tipps. I finally managed to get our zero-downtime deployment working with the following settings:

# eureka server
eureka.server.response-cache-update-interval-ms: 1000

# gateway
eureka.client.registry-fetch-interval-seconds: 5
ribbon.ServerListRefreshInterval: 5000

Our services will unregister from eureka and wait 15 secods before shutting down:

import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
import org.springframework.context.ApplicationListener;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.event.ContextClosedEvent;
import org.springframework.core.Ordered;
import org.springframework.core.annotation.Order;


import lombok.AllArgsConstructor;
import lombok.extern.slf4j.Slf4j;

@ConditionalOnProperty(name = { "eureka.client.enabled", "eureka.client.register-with-eureka" }, matchIfMissing = true)
class EurekaShutdownConfiguration implements ApplicationListener<ContextClosedEvent> {

    private final EurekaClient client;

    public void onApplicationEvent(final ContextClosedEvent event) {
        try {
  "Gracefully shutting down");
        } catch (final InterruptedException e) {


Additionally I'll configure some retry logic on the spring-cloud-gateway for some unexpected other reasons (e.g. server failure and network errors) to be even more failure tolerant

Marcos Barbero
Feb 27 07:40
I'm glad you managed to make it work!
Archimedes Trajano
Feb 27 19:31
Is there a spring-cloud-streams channel?
I just did this
Marcos Barbero
Feb 27 19:32
Spring cloud stream without the extra s
Archimedes Trajano
Feb 27 19:33
there you go
Archimedes Trajano
Feb 27 19:50
yup thanks I asked my question there already.