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
Copy file name to clipboardExpand all lines: content/operate/rs/databases/configure/proxy-policy.md
+60-58Lines changed: 60 additions & 58 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -9,9 +9,9 @@ description: null
9
9
linktitle: Proxy policy
10
10
weight: 40
11
11
---
12
-
Redis Enterprise Software (RS) provides high-performance data access
12
+
Redis Software provides high-performance data access
13
13
through a proxy process that manages and optimizes access to shards
14
-
within the RS cluster. Each node contains a single proxy process.
14
+
within the Redis Software cluster. Each node contains a single proxy process.
15
15
Each proxy can be active and take incoming traffic or it can be passive
16
16
and wait for failovers.
17
17
@@ -25,56 +25,77 @@ A database can have one of the following proxy policies:
25
25
| All primary shards | Multiple proxies are bound to the database, one on each node that hosts a database primary shard. | Most use cases that require multiple endpoints, such as when using the [OSS Cluster API]({{<relref "/operate/rs/clusters/optimize/oss-cluster-api">}}) | Lower latency, fewer network hops, higher throughput | Higher resource usage, more application-to-proxy connections |
26
26
| All nodes | Multiple proxies are bound to the database, one on each node in the cluster, regardless of whether or not there is a shard from this database on the node. | When using [load balancers]({{<relref "/operate/rs/networking/cluster-lba-setup">}}) for environments without DNS | Higher throughput | Highest resource usage |
27
27
28
-
## Database configuration
28
+
## View proxy policy
29
29
30
-
A database can be configured with a proxy policy using rladmin bind.
30
+
You can use the Cluster Manager UI, [`rladmin`]({{<relref "/operate/rs/references/cli-utilities/rladmin">}}), or the [REST API]({{<relref "/operate/rs/references/rest-api">}}) to view proxy configuration settings.
31
31
32
-
Warning: Any configuration update which causes existing proxies to be
33
-
unbounded can cause existing client connections to get disconnected.
34
-
35
-
You can run rladmin to control and view the existing settings for proxy
36
-
configuration.
37
-
38
-
The **info** command on cluster returns the existing proxy policy for
39
-
sharded and non-sharded (single shard) databases.
32
+
The [`rladmin info cluster`]({{<relref "/operate/rs/references/cli-utilities/rladmin/info#info-cluster">}}) command returns the current proxy policy for sharded and non-sharded (single shard) databases.
40
33
41
34
```sh
42
35
$ rladmin info cluster
43
36
cluster configuration:
44
-
repl_diskless: enabled
37
+
...
45
38
default_non_sharded_proxy_policy: single
46
39
default_sharded_proxy_policy: single
47
-
default_shards_placement: dense
48
-
default_shards_overbooking: disabled
49
-
default_fork_evict_ram: enabled
50
-
default_redis_version: 3.2
51
-
redis_migrate_node_threshold: 0KB (0 bytes)
52
-
redis_migrate_node_threshold_percent: 8 (%)
53
-
redis_provision_node_threshold: 0KB (0 bytes)
54
-
redis_provision_node_threshold_percent: 12 (%)
55
-
max_simultaneous_backups: 4
56
-
watchdog profile: local-network
40
+
...
57
41
```
58
42
59
-
You can configure the proxy policy using the `bind` command in
60
-
rladmin. The following command is an example that changes the bind
61
-
policy for a database named "db1" with an endpoint id "1:1" to "All
62
-
primary shards" proxy policy.
43
+
## Configure database proxy policy
44
+
45
+
You can use the [Cluster Manager UI](#cluster-manager-ui-method), the [REST API](#rest-api-method), or [`rladmin`](#command-line-method) to configure a database's proxy policy.
46
+
47
+
{{<warning>}}
48
+
Any configuration update that unbinds existing proxies can disconnect existing client connections.
49
+
{{</warning>}}
50
+
51
+
### Cluster Manager UI method
52
+
53
+
You can change a database's proxy policy when you [create]({{<relref "/operate/rs/databases/create">}}) or [edit]({{<relref "/operate/rs/databases/configure#edit-database-settings">}}) a database using the Cluster Manager UI:
54
+
55
+
1. While in edit mode on the database's configuration screen, expand the **Clustering** section.
56
+
57
+
1. Select a policy from the **Database proxy** list.
58
+
59
+
1. Click **Create** or **Save**.
60
+
61
+
### REST API method
62
+
63
+
You can specify a proxy policy when you [create a database]({{<relref "/operate/rs/references/rest-api/requests/bdbs#post-bdbs-v1">}}) using the REST API:
To change an existing database's proxy policy, you can use an [update database configuration]({{<relref "/operate/rs/references/rest-api/requests/bdbs#put-bdbs">}}) REST API request:
You can configure a database's proxy policy using [`rladmin bind`]({{<relref "/operate/rs/references/cli-utilities/rladmin/bind">}}).
83
+
84
+
The following example changes the bind policy for a database named "db1" with an endpoint ID "1:1" to "All primary shards" proxy policy:
63
85
64
86
```sh
65
87
rladmin bind db db1 endpoint 1:1 policy all-master-shards
66
88
```
67
89
68
-
The next command performs the same task using the database id in place of the name. The id of this database is "1".
90
+
The next command performs the same task using the database ID instead of the name. The ID of this database is "1".
69
91
70
92
```sh
71
93
rladmin bind db db:1 endpoint 1:1 policy all-master-shards
72
94
```
73
95
74
96
{{< note >}}
75
-
You can find the endpoint id for the endpoint argument by running
76
-
*status* command for rladmin. Look for the endpoint id information under
77
-
the *ENDPOINT* section of the output.
97
+
You can find the endpoint ID for the endpoint argument by running `rladmin status`. Look for the endpoint ID information under
98
+
the `ENDPOINT` section of the output.
78
99
{{< /note >}}
79
100
80
101
### Reapply policies after topology changes
@@ -100,44 +121,25 @@ disconnected, and hence might not entirely enforce the policies. In such
100
121
cases, you can enforce the policy using the appropriate rladmin
101
122
commands.
102
123
103
-
## About multiple active proxy support
124
+
## Multiple active proxies
104
125
105
-
RS allows multiple databases to be created. Each database gets an
106
-
endpoint (a unique URL and port on the FQDN). This endpoint receives all
107
-
the traffic for all operations for that database. By default, RS binds
108
-
this database endpoint to one of the proxies on a single node in the
109
-
cluster. This proxy becomes an active proxy and receives all the
110
-
operations for the given database. (note that if the node with the
111
-
active proxy fails, a new proxy on another node takes over as part of
112
-
the failover process automatically).
126
+
Each database you create in a Redis Software cluster has an endpoint, which consists of a unique URL and port on the FQDN. This endpoint receives all the traffic for all operations for that database. By default, Redis Software binds this database endpoint to one of the proxies on a single node in the cluster. This proxy becomes an active proxy and receives all the operations for the given database. If the node with the active proxy fails, a new proxy on another node takes over as part of the failover process automatically.
113
127
114
128
In most cases, a single proxy can handle a large number of operations
115
129
without consuming additional resources. However, under high load,
116
-
network bandwidth or a high rate of packets per second (PPS) on the
130
+
network bandwidth, or a high rate of packets per second (PPS) on the
117
131
single active proxy can become a bottleneck to how fast database
118
-
operation can be performed. In such cases, having multiple active
119
-
proxies, across multiple nodes, mapped to the same external database
132
+
operations can be performed. In such cases, having multiple active proxies across multiple nodes, mapped to the same external database
120
133
endpoint, can significantly improve throughput.
121
134
122
-
With the multiple active proxies capability, RS enables you to configure
123
-
a database to have multiple internal proxies in order to improve
124
-
performance, in some cases. It is important to note that, even though
125
-
multiple active proxies can help improve the throughput of database
135
+
You can configure a database to have multiple internal proxies, which can improve performance in some cases.
136
+
Even though multiple active proxies can help improve the throughput of database
126
137
operations, configuring multiple active proxies may cause additional
127
138
latency in operations as the shards and proxies are spread across
128
139
multiple nodes in the cluster.
129
140
130
141
{{< note >}}
131
-
When the network on a single active proxy becomes the bottleneck,
132
-
you might also look into enabling the multiple NIC support in RS. With
133
-
nodes that have multiple physical NICs (Network Interface Cards), you
134
-
can configure RS to separate internal and external traffic onto
135
-
independent physical NICs. For more details, refer to [Multi-IP &
When the network on a single active proxy becomes the bottleneck, consider enabling multiple NIC support in Redis Software. With nodes that have multiple physical NICs (Network Interface Cards), you can configure Redis Software to separate internal and external traffic onto independent physical NICs. For more details, refer to [Multi-IP & IPv6]({{< relref "/operate/rs/networking/multi-ip-ipv6.md" >}}).
137
143
{{< /note >}}
138
144
139
-
Having multiple proxies for a database can improve RS's ability for fast
140
-
failover in case of proxy and/or node failure. With multiple proxies for
141
-
a database, there is no need for a client to wait for the cluster
142
-
to spin up another proxy and a DNS change in most cases, the client
143
-
just uses the next IP in the list to connect to another proxy.
145
+
Having multiple proxies for a database can improve Redis Software's ability forfast failoverincase of proxy or node failure. With multiple proxies fora database, a client doesn't need to wait for the cluster to spin up another proxy and a DNS changein most cases. Instead, the client uses the next IP address in the list to connect to another proxy.
0 commit comments