-
Notifications
You must be signed in to change notification settings - Fork 0
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
Administration/Clustering: Reference articles about scaling clusters #46
Conversation
591443c
to
66f95aa
Compare
This comment was marked as resolved.
This comment was marked as resolved.
66f95aa
to
672e483
Compare
789bc58
to
d1fe6a0
Compare
(scaling-expand)= | ||
## Expand Cluster | ||
|
||
The article about [how to add new nodes to an existing cluster] walks you | ||
through the process of scaling up your database cluster, and educates you | ||
about the corresponding details to consider. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We haven't been able to discover a meaningful/representative code snippet/example on https://community.cratedb.com/t/how-to-add-new-nodes-to-an-existing-cluster/1546, so we just omitted it in this case.
The whole section is a bit thin now, and could be expanded if you have any ideas/suggestions. Otherwise, let's just merge to make progress.
(scaling-ondemand)= | ||
## On-Demand Scaling | ||
|
||
The article about [scaling CrateDB clusters up and down to cope with peaks in | ||
demand] shares knowledge about the [shard allocation filtering] feature of | ||
CrateDB. | ||
|
||
Along the lines, it demonstrates how this functionality is applied in a real- | ||
world data management scenario, which is about tuning your database cluster to | ||
cope with high-demand situations. | ||
|
||
Prepare adding extra nodes to the database cluster. | ||
```sql | ||
/* Apply routing setting to all existing partitions and new partitions. */ | ||
ALTER TABLE test SET ("routing.allocation.exclude.storage" = 'temporarynodes'); | ||
|
||
/* Configure the setting to be excluded / not applied to _new_ partitions. */ | ||
ALTER TABLE ONLY test RESET ("routing.allocation.exclude.storage"); | ||
``` | ||
|
||
Before the high-demand event, properly configure table routing accordingly. | ||
```sql | ||
ALTER TABLE ONLY test SET ("routing.allocation.total_shards_per_node" = 2); | ||
``` | ||
|
||
To decommission extra database nodes, we need to move the data collected during | ||
the days of the event. | ||
```sql | ||
-- Move the collected data off the extra nodes. | ||
ALTER TABLE test SET ("routing.allocation.exclude.storage" = 'temporarynodes'); | ||
ALTER TABLE test RESET ("routing.allocation.total_shards_per_node"); | ||
|
||
-- Invoke the decommissioning. | ||
ALTER CLUSTER DECOMMISSION 'nodename'; | ||
``` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please don't hesitate to submit suggestions to improve the wording on both guiding comments, and inline comments. Thanks!
Thanks for approving. In order to bring it in, GH-41 also needs approval, because this patch is stacked upon it. |
714c0b2
to
c4439f4
Compare
... linking to community forum article "How to add new nodes to an existing cluster". -- https://community.cratedb.com/t/how-to-add-new-nodes-to-an-existing-cluster/1546
56f9a83
to
8198f08
Compare
About
The dedicated "Expand Cluster" page now cross links to two community forum articles by @hlcianfagna. Thank you again. 🌻
Preview
https://cratedb-guide--46.org.readthedocs.build/admin/clustering/scale-up-down.html
/cc @karynzv, @marijaselakovic, @seut, @surister, @wierdvanderhaar, @matkuliak, @msbt