Skip to content
This repository has been archived by the owner on Nov 12, 2024. It is now read-only.

Shouldn't necessarily initialize matchIndex to -1 #60

Open
colin-scott opened this issue Aug 8, 2015 · 2 comments
Open

Shouldn't necessarily initialize matchIndex to -1 #60

colin-scott opened this issue Aug 8, 2015 · 2 comments
Labels

Comments

@colin-scott
Copy link
Contributor

At the point where a candidate becomes elected and initializes its matchIndex, it may already have entries in its log. If so, it should set its own matchIndex to a non-zero value, otherwise it will never count itself in the quorum for those entries.

@colin-scott colin-scott changed the title Should Shouldn't necessarily initialize matchIndex to -1 Aug 8, 2015
@colin-scott
Copy link
Contributor Author

Well, arguably a bug: it decreases the fault-tolerance of the cluster by 1 for all terms where that leader is elected, i.e. progress won't be made if f-1 nodes fail

@ktoso
Copy link
Owner

ktoso commented Aug 8, 2015

Thanks for clarifying, classifying as bug;

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

2 participants