Open ishan-juspay opened 1 year ago
I'm personally not a huge fan of hiding connection pool details into the package and not giving an access.
While it has some benefits like automatic reconnection using Redis-cluster or sentinel protocols, it does not give a user ability to express all the requirements of the particular system and complex algorithms. In our cases requirements were to have a back pressure algorithms to avoid cascading failures. So I'd rather see connection exposed and possibly some library helpers that implements most common scenarios.
However I never used Redis-cluster and at work we are using sentinel so I may miss particular.
So I really would trust the approach suggested by cluster users, and as far as I understand Juspay developers are such users.
Currently for Clustered Redis connection pool management, we treat each resource of the pool as a list of active connection to each node of the cluster. This has the following problems:
Idea is to explore if there should be a connection pool per node of the Redis cluster to solve this?