Documentation ¶
Index ¶
- type EntryStore
- func (es *EntryStore) Append(entries []pb.Entry) error
- func (es *EntryStore) ApplySnapshot(snap pb.Snapshot) error
- func (es *EntryStore) Close() error
- func (es *EntryStore) Compact(compactIndex uint64) error
- func (es *EntryStore) CreateSnapshot(i uint64, cs *pb.ConfState, data []byte) (pb.Snapshot, error)
- func (es *EntryStore) Entries(lo, hi, maxSize uint64) ([]pb.Entry, error)
- func (es *EntryStore) FirstIndex() (uint64, error)
- func (es *EntryStore) InitialState() (pb.HardState, pb.ConfState, error)
- func (es *EntryStore) LastIndex() (uint64, error)
- func (es *EntryStore) SetHardState(st pb.HardState) error
- func (es *EntryStore) Snapshot() (pb.Snapshot, error)
- func (es *EntryStore) Term(i uint64) (uint64, error)
- type RaftStorageEngine
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type EntryStore ¶
EntryStore implements the Storage interface backed by an SS table. Specifically we use the implementation from Badger for storing entries in sorted manner.
func NewEntryStore ¶
func NewEntryStore(entryDir string) (*EntryStore, error)
func (*EntryStore) ApplySnapshot ¶
func (es *EntryStore) ApplySnapshot(snap pb.Snapshot) error
func (*EntryStore) Close ¶
func (es *EntryStore) Close() error
func (*EntryStore) Compact ¶
func (es *EntryStore) Compact(compactIndex uint64) error
func (*EntryStore) CreateSnapshot ¶
func (*EntryStore) Entries ¶
func (es *EntryStore) Entries(lo, hi, maxSize uint64) ([]pb.Entry, error)
func (*EntryStore) FirstIndex ¶
func (es *EntryStore) FirstIndex() (uint64, error)
func (*EntryStore) InitialState ¶
func (*EntryStore) LastIndex ¶
func (es *EntryStore) LastIndex() (uint64, error)
func (*EntryStore) SetHardState ¶
func (es *EntryStore) SetHardState(st pb.HardState) error
Click to show internal directories.
Click to hide internal directories.