Automated replica setup and recovery
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 668
- Forks
- 135
- Avg merge
- 4d 19h
- Merged PRs (30d)
- 7
Description
Currently, there's no automated way to set up a new replica or to replace a broken replica. A user has to perform `rsync` from an existing healthy replica's data directory using command-line interface, which is obviously error-prone.
We should implement internal remote API:
- restricted to inter-replica communication
- dedicated to replica setup and recovery
.. so that configuring a new replica is as simple as running a single command. For example:
```
$ cd centraldogma/bin
$ ./setup-replica 192.168.0.100:36462 # the IP address and port of an existing healthy replica
... retrieves conf/* and lib/ext/* ...
... generates UUID and writes to conf/dogma.json ...
... retrieves all repository data ...
$ ./startup
... a new replica joins the cluster ...
```
In case of recovery, you could simply wipe out the existing `data` and `conf` directory and run `setup-replica`.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Use centraldogma/bin/setup-replica and startup as the named entry points; trace the existing inter-replica communication and the conf, lib/ext, and data layouts before deciding where setup and recovery belong. Done means a single setup-replica command can retrieve the required configuration and repository data, generate a UUID in conf/dogma.json, and let the new replica join after startup.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- distributed-systems
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 32/100