Documentation
¶
Overview ¶
Package seq provides atomic sequence counters.
Generates monotonically increasing commit and transaction IDs.
Related Packages ¶
- github.com/signadot/tony-format/go-tony/system/logd/storage - Storage layer
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Seq ¶
func (*Seq) CurrentSeqState ¶
CurrentSeqState returns the current sequence state without incrementing.
func (*Seq) NextCommit ¶
NextCommit atomically increments and returns the next commit count.
func (*Seq) NextCommitLocked ¶
func (*Seq) NextTxSeq ¶
NextTxSeq atomically increments and returns the next transaction sequence number.
func (*Seq) ReadStateLocked ¶
readSeqState reads the sequence state from disk. Caller must hold seqMu lock.
func (*Seq) WriteStateLocked ¶
WriteStateLocked writes the sequence state to disk atomically. Caller must hold seqMu lock.
Click to show internal directories.
Click to hide internal directories.