#1665·ioredis

Difference between sentinelReconnectStrategy & sentinelRetryStrategy

Author: ramprasad1996Created Oct 18, 2022Updated Aug 22, 2026
Labelsstale

Hi,

We have a nodejs based app that uses ioredis in a kubernetes setup to connect to redis sentinels. When the redis master is down, the app pods detects the failover and works fine, but in rare cases, the app is still unable to connect to redis after failover.

We did not close the redisClient when this issue occurs. We need to retry for few times if it is able to reconnect back. For this case, which property should I use between the two sentinelReconnectStrategy & sentinelRetryStrategy to retry few times before closing the client?

What is the difference between sentinelReconnectStrategy & sentinelRetryStrategy ?

@luin