walstore

package
v0.16.5-rc.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 8, 2026 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DefaultWALDir

func DefaultWALDir(dbPath string) string

Types

type TendermintWALStore

type TendermintWALStore[V types.Hashable[H], H types.Hash, A types.Addr] interface {
	// Flush writes pending records to the WAL.
	Flush() error
	// LoadAllEntries returns stored WAL entries ordered by height.
	LoadAllEntries() iter.Seq2[wal.Entry[V, H, A], error]
	// SetWALEntry buffers an entry until Flush or Close.
	SetWALEntry(entry wal.Entry[V, H, A]) error
	// DeleteWALEntries buffers a prune for all entries up to and including height.
	DeleteWALEntries(height types.Height) error
	// Close flushes pending records and closes WAL resources.
	Close() error
}

TendermintWALStore persists consensus WAL entries so the node can recover after a crash.

func NewTendermintWALStore

func NewTendermintWALStore[V types.Hashable[H], H types.Hash, A types.Addr](
	database kvdb.KeyValueStore,
) (TendermintWALStore[V, H, A], error)

NewTendermintWALStore creates a new TendermintWALStore backed by Pebble's standalone WAL implementation.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL