Skip to content

Changed dynamic_startup_nodes default value to 'True' #2251

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Jun 27, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -1268,15 +1268,15 @@ Using scripting within pipelines in cluster mode is **not supported**.
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)
dynamic_startup_nodes: (default=True)

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.
specific IP addresses, it is best to set it to false.

cluster_error_retry_attempts: (default=3)

Expand Down
10 changes: 5 additions & 5 deletions redis/cluster.py
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,7 @@ def __init__(
require_full_coverage=False,
reinitialize_steps=10,
read_from_replicas=False,
dynamic_startup_nodes=False,
dynamic_startup_nodes=True,
url=None,
**kwargs,
):
Expand Down Expand Up @@ -512,12 +512,12 @@ def __init__(
primary and its replications in a Round-Robin manner.
:dynamic_startup_nodes: 'bool'
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.
If true (default value), 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.
specific IP addresses, it is best to set it to false.
:cluster_error_retry_attempts: 'int'
Retry command execution attempts when encountering ClusterDownError
or ConnectionError
Expand Down Expand Up @@ -1293,7 +1293,7 @@ def __init__(
from_url=False,
require_full_coverage=False,
lock=None,
dynamic_startup_nodes=False,
dynamic_startup_nodes=True,
**kwargs,
):
self.nodes_cache = {}
Expand Down