Spring Cloud Server: configure git output interval

I am using a Spring Cloud Configuration Server connected to an Eureka server with a BitBucket git repository. I found in the debugger that it org.eclipse.jgit.api.PullCommand#callis called through the scheduler every time Config Server updates its status using Eureka. Moreover, it is called every time the connected services request an updated configuration, and even every time the endpoint is requested /healthon the Spring Cloud Config Server or on the connected client.

I believe this is a big overhead in terms of HTTP response time, but also outbound traffic.

Is there a way to update a locally cloned repository less often?

PS I know that there is a Backend File System , or I can point Config Server to a locally cloned local (i.e. file:///) repository. But I wonder if there is such functionality out of the box.

+4
source share
1 answer

You can disable the health indicator on the configuration server through spring.cloud.config.server.health.enabled=falseand health.config.enabled=falsein the configuration client. Requests to the configuration server are always cloned, so you need to disable or disable health checks.

+3
source

All Articles