Skip to content
Snippets Groups Projects
Commit 77098294 authored by Konstantin Belyavskiy's avatar Konstantin Belyavskiy Committed by Konstantin Osipov
Browse files

replication: fix bug with read-only replica as a bootstrap leader

Another broken case. Adding a new replica to cluster:
+		if (replica->applier->remote_is_ro &&
+		    replica->applier->vclock.signature == 0)
In this case we may got an ER_READONLY, since signature is not 0.
So leader election now has two phases:
 1. To select among read-write replicas.
 2. If no such found, try old algorithm for backward compatibility
    (case then all replicas exist in cluster table).

Closes #3257
parent 861803ee
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment