Jonathan Schuster

Results 27 issues of Jonathan Schuster

The Candidate state does not distinguish between multiple votes in the same term from the same follower, although it should. Otherwise, a candidate might get elected by the same follower...

protocol-fix

There are a few instances in which a server in a given state will not handle a given protocol message. Usually these messages would not be sent to servers in...

protocol-fix

In `AppendEntries.apply`, if a batch is empty (e.g. because the follower is completely caught up and we're sending a heartbeat), the message is sent with `prevLogTerm` 1 and `prevLogIndex` 1....

protocol-fix

The call to ReplicatedLog.append in the Follower's append code does not take log compaction into account. If a log has been compacted, then taking a number of entries equal to...

protocol-fix

This test puts the first entry in the log at index 1, even though the log really starts at index 0. Again, this seems related to the inconsistent use of...

protocol-fix

The `termAt` method will return the wrong term in the case where the first entry in the log actually comes from a term other than term 1 (could happen if...

protocol-fix

The index numbers used in the code are confusing and seem to be inconsistent. The indices in the log will start at 0. However, an `AppendEntries` with an empty list...

protocol-fix

If I'm reading the code correctly, `nextIndex` is based on the number of entries in the log. This won't work when log compaction is used, because a single compacted log...

protocol-fix

When a candidate responds to a `RequestVote` with `DeclineCandidate`, it should include its own term in the response instead of the request's term. This allows the candidate that sent the...

protocol-fix