@@ -169,21 +169,21 @@ CREATE TABLE partitions (
169
169
);
170
170
171
171
move_part(part_name text, dest int, src int DEFAULT NULL)
172
- Move shard 'part_name' from node 'dest' to node 'src'. If src is NULL, primary
173
- shard is moved. Cmd fails if there is already replica of this shard on 'dest'.
172
+ Move shard 'part_name' from node 'src' to node 'dest'. If src is NULL, primary
173
+ shard is moved. Cmd fails if there is already copy of this shard on 'dest'.
174
+
175
+ rebalance(relation text)
176
+ Evenly distribute all partitions including replicas of table 'relation' across
177
+ all nodes. Currently this is pretty dumb function, it just tries to move each
178
+ shard once to node choosen in round-robin manner, completely ignoring current
179
+ distribution. Since dest node can already have replica of this partition, it is
180
+ not uncommon to see warnings about failed moves during execution. After
181
+ completion cmd status is 'done', not 'success'.
174
182
175
183
create_replica(part_name text, dest int)
176
184
Create replica of shard 'part_name' on node 'dest'. Cmd fails if there is already
177
185
replica of this shard on 'dest'.
178
186
179
- rebalance(relation text)
180
- Evenly distribute partitions of table 'relation' across all nodes. Currently
181
- this is pretty dumb function, it just tries to move each shard once to node
182
- choosen in round-robin manner, completely ignoring current distribution. Since
183
- dest node can already have replica of this partition, it is not uncommon to see
184
- warnings about failed moves during execution. After completion cmd status is
185
- 'done', not 'success'.
186
-
187
187
set_replevel(relation text, replevel int)
188
188
Add replicas to shards of sharded table 'relation' until we reach replevel
189
189
replicas for each one, i.e. until each shard has 'replevel' read-only replicas.
0 commit comments