·7 min read
A slow reconnect can mark a dead Redis connection as healthy
Two reconnect attempts overlap, the slow one finishes last, and your client now trusts a socket that is already gone. ioredis stops this with a single counter. Here is the race, in 30 lines you can run.