summaryrefslogtreecommitdiff
path: root/README.md
diff options
context:
space:
mode:
authorBar Shaul <88437685+barshaul@users.noreply.github.com>2022-06-23 19:28:02 +0300
committerGitHub <noreply@github.com>2022-06-23 19:28:02 +0300
commit63cf7ec5cbaca533b7607196dbf993917a65c0f9 (patch)
treefd02285634cdd1d7978e5c521edf89b201bb94a0 /README.md
parentd3a7a75c7b106e0864b3927c0904058e25c99958 (diff)
downloadredis-py-63cf7ec5cbaca533b7607196dbf993917a65c0f9.tar.gz
Added dynamic_startup_nodes configuration to RedisCluster. (#2244)
* Added dynamic_startup_nodes configuration to RedisCluster. By default, uses only the initial passed startup nodes to refresh the cluster topology. If set to true, sets the startup nodes to all of the discovered nodes. * Added RedisCluster specific options to the README file and updated CHANGES * Fixed timeout_error_topology_refresh test Co-authored-by: dvora-h <67596500+dvora-h@users.noreply.github.com>
Diffstat (limited to 'README.md')
-rw-r--r--README.md50
1 files changed, 50 insertions, 0 deletions
diff --git a/README.md b/README.md
index f5d4ae5..64c9d28 100644
--- a/README.md
+++ b/README.md
@@ -1006,6 +1006,7 @@ a slots cache which maps each of the 16384 slots to the node/s handling them,
a nodes cache that contains ClusterNode objects (name, host, port, redis connection)
for all of the cluster's nodes, and a commands cache contains all the server
supported commands that were retrieved using the Redis 'COMMAND' output.
+See *RedisCluster specific options* below for more.
RedisCluster instance can be directly used to execute Redis commands. When a
command is being executed through the cluster instance, the target node(s) will
@@ -1245,6 +1246,55 @@ The following commands are not supported:
Using scripting within pipelines in cluster mode is **not supported**.
+
+**RedisCluster specific options**
+
+ require_full_coverage: (default=False)
+
+ When set to False (default value): the client will not require a
+ full coverage of the slots. However, if not all slots are covered,
+ and at least one node has 'cluster-require-full-coverage' set to
+ 'yes,' the server will throw a ClusterDownError for some key-based
+ commands. See -
+ https://redis.io/topics/cluster-tutorial#redis-cluster-configuration-parameters
+ When set to True: all slots must be covered to construct the
+ cluster client. If not all slots are covered, RedisClusterException
+ will be thrown.
+
+ read_from_replicas: (default=False)
+
+ Enable read from replicas in READONLY mode. You can read possibly
+ stale data.
+ When set to true, read commands will be assigned between the
+ primary and its replications in a Round-Robin manner.
+
+ dynamic_startup_nodes: (default=False)
+
+ Set the RedisCluster's startup nodes to all of the discovered nodes.
+ If true, the cluster's discovered nodes will be used to determine the
+ cluster nodes-slots mapping in the next topology refresh.
+ It will remove the initial passed startup nodes if their endpoints aren't
+ listed in the CLUSTER SLOTS output.
+ If you use dynamic DNS endpoints for startup nodes but CLUSTER SLOTS lists
+ specific IP addresses, keep it at false.
+
+ cluster_error_retry_attempts: (default=3)
+
+ Retry command execution attempts when encountering ClusterDownError
+ or ConnectionError
+
+ reinitialize_steps: (default=10)
+
+ Specifies the number of MOVED errors that need to occur before
+ reinitializing the whole cluster topology. If a MOVED error occurs
+ and the cluster does not need to be reinitialized on this current
+ error handling, only the MOVED slot will be patched with the
+ redirected node.
+ To reinitialize the cluster on every MOVED error, set
+ reinitialize_steps to 1.
+ To avoid reinitializing the cluster on moved errors, set
+ reinitialize_steps to 0.
+
### Author
redis-py is developed and maintained by [Redis Inc](https://redis.com). It can be found [here](