diff --git a/toy-raft/raft/badger_store.go b/toy-raft/raft/badger_store.go index 7fa17cb..252c91d 100644 --- a/toy-raft/raft/badger_store.go +++ b/toy-raft/raft/badger_store.go @@ -272,6 +272,7 @@ func (store *BadgerStorage) idxToKey(idx uint64) []byte { return []byte(fmt.Sprintf("%d", idx)) } +// TODO should return index so caller can check it matches expected (alternatively, pass in the expected index) func (store *BadgerStorage) AppendEntry(entry Entry) error { if store.GetCurrentTerm() == 0 { assert.Unreachable(