Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit fb13d4b

Browse files
committed
Readme update.
set_replevel clarified, note on permissions added.
1 parent ecc1223 commit fb13d4b

File tree

1 file changed

+15
-9
lines changed

1 file changed

+15
-9
lines changed

readme.txt

Lines changed: 15 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,9 @@ which is useful for development.
2222
Both shardlord and workers require extension built and installed. We depend
2323
on pg_pathman extension so it must be installed too.
2424
PostgreSQL location for building is derived from pg_config, you can also specify
25-
path to it in PG_CONFIG var. PostgreSQL 10 (master branch as of writing this)
26-
is required. The whole process of building and copying files to PG server is just:
25+
path to it in PG_CONFIG var. PostgreSQL 10 (REL_10_STABLE branch as of writing
26+
this) is required. Extension links with libpq, so if you The whole process of
27+
building and copying files to PG server is just:
2728

2829
git clone
2930
cd pg_shardman
@@ -85,9 +86,9 @@ that's easy to change.
8586
Let's get to the actual commands.
8687

8788
add_node(connstring text)
88-
Add node with given connstring to the cluster. Node is assigned unique id. If
89-
node previously contained shardman state from old cluster (not one managed by
90-
current shardlord), this state will be lost.
89+
Add node with given libpq connstring to the cluster. Node is assigned unique
90+
id. If node previously contained shardman state from old cluster (not one
91+
managed by current shardlord), this state will be lost.
9192

9293
rm_node(node_id int)
9394
Remove node from the cluster. Its shardman state will be reset. We don't delete
@@ -163,15 +164,20 @@ warnings about failed moves during execution. After completion cmd status is
163164

164165
set_replevel(relation text, replevel int)
165166
Add replicas to shards of sharded table 'relation' until we reach replevel
166-
replicas for each one. Replica deletions is not implemented yet. Note that it is
167-
pointless to set replevel to more than number of active workers - 1 since we
167+
replicas for each one, i.e. until each shard has 'replevel' read-only replicas.
168+
replevel 0 has no effect. Replica deletions is not implemented yet. Note that it
169+
is pointless to set replevel more than number of active workers - 1 since we
168170
don't forbid several replicas on one node. Nodes for replicas are choosen
169171
randomly. As in 'rebalance', we are fully oblivious about current shards
170-
distribution, so you will see a bunch of warnings about failing replica
171-
creation -- one for each time random chooses node with already existing replica.
172+
distribution, so you will see a bunch of warnings about failing replica creation
173+
-- one for each time random had chosen node with already existing replica.
172174

173175
Sharded tables dropping, as well as replica deletion is not implemented yet.
174176

177+
Note on permissions: since creating subscription requires superuser priviliges,
178+
connections strings provided to add_node, as well as shardlord_connstring GUC
179+
must be of superuser ones. This might be relaxed in the future.
180+
175181
Limitations:
176182
* We are bound to Linux since we use epoll, select should be added.
177183
* We can't switch shardlord for now.

0 commit comments

Comments
 (0)