-
Notifications
You must be signed in to change notification settings - Fork 241
Consul Cache #81
Comments
The Consul Client throws a |
It is a problem. every TimeoutException we have a printing to log, and kvClient.getValues method is executed again. so the watchTimeout(KVCache argument) is useless. The exception caused from using: solve this with configure the Client with another timeout value, and build Consul using .withClientBuilder() constructor. BUT! when initializing KVCache, the watchTimeout is limited up to 10m. Enjoy :) |
The latest consul-client has use OkHttp now, so if you encounter this situation, you could make read timeout longer use Consul consul = Consul.builder()
.withReadTimeoutMillis(60 * 1000) // 60 seconds
.build(); |
Hi ,
I am trying to use consul cache and i keep getting the following error :
ERROR com.orbitz.consul.cache.ConsulCache - Error getting response from consul. will retry in 10 SECONDS
why do i get this error??
code example:
LOGGER.info("Initializing consul cache!!!!!");
com.orbitz.consul.Consul consul = com.orbitz.consul.Consul.builder().build();
KeyValueClient kvClient = consul.keyValueClient();
The text was updated successfully, but these errors were encountered: