Read-only status for shards
Adds a read-only state for shards that is enabled when a failover happens. While the functionality is also implemented in local elector, the read only mode is only persisted in memory and won't carry over between praefect restarts nor shared between multiple nodes.
This commit only adds the functionality required for enabling read-only after a failover. The read-only state is not exposed or enforced in any RPCs or replication jobs yet.
Related to #2630 (closed). Depends on !2105 (merged), reviewing will be easier if you only look at the changes introduced in the last commit.
Edited by GitLab Release Tools Bot