Documentation
¶
Index ¶
- Constants
- Variables
- func InitBG(wl AbstractWAL)
- func MustMarshal(entry *WALEntry) []byte
- func MustUnmarshal(data []byte, entry *WALEntry)
- func ShutdownBG()
- type AOF
- type AbstractWAL
- type WALEntry
- func (*WALEntry) Descriptor() ([]byte, []int)deprecated
- func (x *WALEntry) GetCrc32() uint32
- func (x *WALEntry) GetData() []byte
- func (x *WALEntry) GetLogSequenceNumber() uint64
- func (x *WALEntry) GetTimestamp() int64
- func (x *WALEntry) GetVersion() string
- func (*WALEntry) ProtoMessage()
- func (x *WALEntry) ProtoReflect() protoreflect.Message
- func (x *WALEntry) Reset()
- func (x *WALEntry) String() string
- type WALNull
Constants ¶
View Source
const ( RotationModeTime = "time" RetentionModeTime = "time" WALModeUnbuffered = "unbuffered" )
View Source
const (
CRCSize = 4
)
Variables ¶
View Source
var File_internal_wal_wal_proto protoreflect.FileDescriptor
Functions ¶
func InitBG ¶
func InitBG(wl AbstractWAL)
func MustUnmarshal ¶
func ShutdownBG ¶
func ShutdownBG()
Types ¶
type AOF ¶
type AOF struct {
// contains filtered or unexported fields
}
func (*AOF) ForEachCommand ¶
func (*AOF) LogCommand ¶
WriteEntry writes an entry to the WAL.
type AbstractWAL ¶
type WALEntry ¶
type WALEntry struct { Version string `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"` // Version of the WAL entry (e.g., "v1.0") LogSequenceNumber uint64 `protobuf:"varint,2,opt,name=log_sequence_number,json=logSequenceNumber,proto3" json:"log_sequence_number,omitempty"` // Log Sequence Number (LSN) Data []byte `protobuf:"bytes,3,opt,name=data,proto3" json:"data,omitempty"` // The actual data being logged Crc32 uint32 `protobuf:"varint,4,opt,name=crc32,proto3" json:"crc32,omitempty"` // Cyclic Redundancy Check for integrity Timestamp int64 `protobuf:"varint,5,opt,name=timestamp,proto3" json:"timestamp,omitempty"` // Timestamp for the WAL entry (epoch time in nanoseconds) // contains filtered or unexported fields }
func (*WALEntry) Descriptor
deprecated
func (*WALEntry) GetLogSequenceNumber ¶
func (*WALEntry) GetTimestamp ¶
func (*WALEntry) GetVersion ¶
func (*WALEntry) ProtoMessage ¶
func (*WALEntry) ProtoMessage()
func (*WALEntry) ProtoReflect ¶
func (x *WALEntry) ProtoReflect() protoreflect.Message
type WALNull ¶
type WALNull struct { }
func NewNullWAL ¶
func (*WALNull) ForEachCommand ¶
func (*WALNull) LogCommand ¶
LogCommand serializes a WALLogEntry and writes it to the current WAL file.
Click to show internal directories.
Click to hide internal directories.