-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
## Summary: Initial cluster configuration and handling - Defines cluster config structure - Regularly fetch cluster config from the metadata store - Single node uses replicated loglet by default - Proper tooling to reconfigure the cluster ## Configuration file Introduce a new configuration ```toml cluster-configuration = "empty|default" ``` By setting this to "default" (that the the default value) the node seeds the cluster configuration with default config Setting `cluster-configuration` to empty. Starts the node with empty cluster configuration. In that case, the node does not provision the partition table or the logs until the configuration is set explicitly via `restatectl cluster config set` Once configuration is set, the configuration of the cluster auto resumes. No extra actions are needed. ## `cluster config get/set` `restatectl cluster config` gives users a simple interface to inspect and update configuration ### Example ``` restatectl cluster config get ⚙️ Version: 1: ――――――――――――― num-partitions = 24 default-provider = "local" nodeset-selection-strategy = "strict-fault-tolerant-greedy" partition-processor-replication-strategy = "on-all-nodes" [replication-property] node = 1 ``` To change the config, create a new toml file with following content cluster-config-example.toml ```toml num-partitions = 24 default-provider = "local" nodeset-selection-strategy = "strict-fault-tolerant-greedy" [partition-processor-replication-strategy] factor = 2 [replication-property] node = 2 ``` Then run ``` restatectl cluster config set cluster-config-example.toml num-partitions = 24 default-provider = "local" nodeset-selection-strategy = "strict-fault-tolerant-greedy" -partition-processor-replication-strategy = "on-all-nodes" [replication-property] -node = 1 +node = 2 + +[partition-processor-replication-strategy] +factor = 2 💡 Please note that changes in configuration can take up to 5 seconds before they are seen by all nodes. If Configuration is being set for the first time. The system will initialize the logs with the given configuration. Changes of configuration does not automatically trigger a reconfigure of the logs. Reconfiguration will happen when detected to be needed by the system or by using the `restatectl cluster reconfigure` command. ? Apply changes? (y/n) › no ```
- Loading branch information
1 parent
07882c3
commit e050319
Showing
28 changed files
with
1,493 additions
and
270 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.