lettuce-core: Getting "RedisCommandTimeoutException: Command timed out" frequently

I am using 4.1.2.Final version to connect to Redis Sentinel cluster. It works fine for some time after app starts, Then after some time, when I execute any command, It tries to connect and throws RedisCommandTimeoutException. After that, It reconnects automatically. and work fine again. This process goes on. I am using dropwizard framework and initializing CacheFactory ( which handle connection) when the application starts.

Logs

com.lambdaworks.redis.RedisCommandTimeoutException: Command timed out
    at com.lambdaworks.redis.LettuceFutures.await(LettuceFutures.java:95) ~[compliance-api.jar:0.0.1]
    at com.lambdaworks.redis.LettuceFutures.awaitOrCancel(LettuceFutures.java:74) ~[compliance-api.jar:0.0.1]
    at com.lambdaworks.redis.FutureSyncInvocationHandler.handleInvocation(FutureSyncInvocationHandler.java:63) ~[compliance-api.jar:0.0.1]
    at com.google.common.reflect.AbstractInvocationHandler.invoke(AbstractInvocationHandler.java:87) ~[compliance-api.jar:0.0.1]
    at com.sun.proxy.$Proxy70.get(Unknown Source) ~[na:na]

Log when reconnects

[lettuce-eventExecutorLoop-5-3] [ConnectionWatchdog]: Reconnecting, last destination was /10.X.X.X:6379
[lettuce-eventExecutorLoop-5-3] [ConnectionWatchdog]: Reconnected to /10.X.X.X:6379.

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 19 (9 by maintainers)

Most upvoted comments

It is working fine till now. Will update again by EOD.

Thanks a lot.