You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
the initialization is taking too long because it sends a command INFO to check if the cluster is enabled, references:
# Make sure cluster mode is enabled on this nodeifbool(r.info().get("cluster_enabled")) isFalse:
raiseRedisClusterException(
"Cluster mode is not enabled on this node"
)
cluster_slots=str_if_bytes(r.execute_command("CLUSTER SLOTS"))
startup_nodes_reachable=True
Since my cluster is big, this command is taking too long, that is not a big issue, because it runs only in the initialization, but the problem is that my requests are very fast, we use a pipeline and get so the majority of requests are below 5ms and I wanna configure a timeout for something like 100ms or even 50ms, but since the timeout parameter is configured only in the initialization of the cluster and it is taking a few seconds to initialize, I need to inform a bigger timeout on the constructor.
Saying all that, I have two questions, (1) is it possible to change the timeout after creating the client? If not, we can change the way it validates if the cluster is enabled to a faster command or even skip this validation?
The text was updated successfully, but these errors were encountered:
Version: 5.0.1
Platform: Python 3.8, Ubuntu 22.04
Description:
Hello guys, I'm upgrading the library from a very old version, from redis-py-cluster. I notice that when creating the client, for instance:
the initialization is taking too long because it sends a command INFO to check if the cluster is enabled, references:
Since my cluster is big, this command is taking too long, that is not a big issue, because it runs only in the initialization, but the problem is that my requests are very fast, we use a pipeline and get so the majority of requests are below 5ms and I wanna configure a timeout for something like 100ms or even 50ms, but since the timeout parameter is configured only in the initialization of the cluster and it is taking a few seconds to initialize, I need to inform a bigger timeout on the constructor.
Saying all that, I have two questions, (1) is it possible to change the timeout after creating the client? If not, we can change the way it validates if the cluster is enabled to a faster command or even skip this validation?
The text was updated successfully, but these errors were encountered: