Versions in this module Expand all Collapse all v1 v1.0.0 Jul 19, 2024 Changes in this version + const NoNode + const RaftEntryEncodingScheme + var ChecksumType_name = map[int32]string + var ChecksumType_value = map[string]int32 + var ColferSizeMax uint64 = 8 * 1024 * 1024 * 1024 * 1024 + var CompressionType_name = map[int32]string + var CompressionType_value = map[string]int32 + var ConfigChangeType_name = map[int32]string + var ConfigChangeType_value = map[string]int32 + var EntryType_name = map[int32]string + var EntryType_value = map[string]int32 + var ErrIntOverflowRaft = fmt.Errorf("proto: integer overflow") + var ErrInvalidLengthRaft = fmt.Errorf("proto: negative length found during unmarshaling") + var LastChunkCount uint64 = math.MaxUint64 + var MessageType_name = map[int32]string + var MessageType_value = map[string]int32 + var PoisonChunkCount uint64 = math.MaxUint64 - 1 + var StateMachineType_name = map[int32]string + var StateMachineType_value = map[string]int32 + func GetEntrySliceInMemSize(ents []Entry) uint64 + func GetEntrySliceSize(ents []Entry) uint64 + func IsEmptySnapshot(s Snapshot) bool + func IsEmptyState(st State) bool + func IsStateEqual(a State, b State) bool + func MustMarshal(m Marshaler) []byte + func MustMarshalTo(m Marshaler, result []byte) []byte + func MustUnmarshal(m Unmarshaler, data []byte) + type Bootstrap struct + Addresses map[uint64]string + Join bool + Type StateMachineType + func NewBootstrapInfo(join bool, smType StateMachineType, nodes map[uint64]string) Bootstrap + func (b *Bootstrap) Validate(nodes map[uint64]string, join bool, smType StateMachineType) bool + func (m *Bootstrap) Marshal() (dAtA []byte, err error) + func (m *Bootstrap) MarshalTo(dAtA []byte) (int, error) + func (m *Bootstrap) Size() (n int) + func (m *Bootstrap) Unmarshal(dAtA []byte) error + type ChecksumType int32 + const CRC32IEEE + const HIGHWAY + func (x ChecksumType) String() string + type Chunk struct + BinVer uint32 + ChunkCount uint64 + ChunkId uint64 + ChunkSize uint64 + Data []byte + DeploymentId uint64 + FileChunkCount uint64 + FileChunkId uint64 + FileInfo SnapshotFile + FileSize uint64 + Filepath string + From uint64 + HasFileInfo bool + Index uint64 + Membership Membership + OnDiskIndex uint64 + ReplicaID uint64 + ShardID uint64 + Term uint64 + Witness bool + func (m *Chunk) Marshal() (dAtA []byte, err error) + func (m *Chunk) MarshalTo(dAtA []byte) (int, error) + func (m *Chunk) Size() (n int) + func (m *Chunk) Unmarshal(dAtA []byte) error + func (m Chunk) IsLastChunk() bool + func (m Chunk) IsLastFileChunk() bool + func (m Chunk) IsPoisonChunk() bool + type ColferError int + func (i ColferError) Error() string + type ColferMax string + func (m ColferMax) Error() string + type ColferTail int + func (i ColferTail) Error() string + type CompressionType int32 + const NoCompression + const Snappy + func (x CompressionType) String() string + type ConfigChange struct + Address string + ConfigChangeId uint64 + Initialize bool + ReplicaID uint64 + Type ConfigChangeType + func (m *ConfigChange) Marshal() (dAtA []byte, err error) + func (m *ConfigChange) MarshalTo(dAtA []byte) (int, error) + func (m *ConfigChange) Size() (n int) + func (m *ConfigChange) Unmarshal(dAtA []byte) error + type ConfigChangeType int32 + const AddNode + const AddNonVoting + const AddWitness + const RemoveNode + func (x ConfigChangeType) String() string + type Entry struct + ClientID uint64 + Cmd []byte + Index uint64 + Key uint64 + RespondedTo uint64 + SeriesID uint64 + Term uint64 + Type EntryType + func EntriesToApply(entries []Entry, applied uint64, strict bool) []Entry + func (m *Entry) IsConfigChange() bool + func (m *Entry) IsEmpty() bool + func (m *Entry) IsEndOfSessionRequest() bool + func (m *Entry) IsNewSessionRequest() bool + func (m *Entry) IsNoOPSession() bool + func (m *Entry) IsProposal() bool + func (m *Entry) IsSessionManaged() bool + func (m *Entry) IsUpdateEntry() bool + func (m *Entry) Marshal() (dAtA []byte, err error) + func (m *Entry) MarshalTo(buf []byte) (int, error) + func (m *Entry) Size() int + func (m *Entry) SizeUpperLimit() int + func (m *Entry) Unmarshal(data []byte) error + type EntryBatch struct + Entries []Entry + func (m *EntryBatch) Marshal() (dAtA []byte, err error) + func (m *EntryBatch) MarshalTo(dAtA []byte) (int, error) + func (m *EntryBatch) Size() (n int) + func (m *EntryBatch) SizeUpperLimit() (n int) + func (m *EntryBatch) Unmarshal(dAtA []byte) error + type EntryType int32 + const ApplicationEntry + const ConfigChangeEntry + const EncodedEntry + const MetadataEntry + func (x EntryType) String() string + type IChunkSink interface + Close func() error + Receive func(chunk Chunk) (bool, bool) + ShardID func() uint64 + ToReplicaID func() uint64 + type ICompactor interface + Compact func(uint64) error + type LeaderUpdate struct + LeaderID uint64 + Term uint64 + type LogQueryResult struct + Entries []Entry + Error error + FirstIndex uint64 + LastIndex uint64 + func (r *LogQueryResult) IsEmpty() bool + type Marshaler interface + Marshal func() ([]byte, error) + MarshalTo func([]byte) (int, error) + type Membership struct + Addresses map[uint64]string + ConfigChangeId uint64 + NonVotings map[uint64]string + Removed map[uint64]bool + Witnesses map[uint64]string + func (m *Membership) Marshal() (dAtA []byte, err error) + func (m *Membership) MarshalTo(dAtA []byte) (int, error) + func (m *Membership) Size() (n int) + func (m *Membership) Unmarshal(dAtA []byte) error + type Message struct + Commit uint64 + Entries []Entry + From uint64 + Hint uint64 + HintHigh uint64 + LogIndex uint64 + LogTerm uint64 + Reject bool + ShardID uint64 + Snapshot Snapshot + Term uint64 + To uint64 + Type MessageType + func (m *Message) CanDrop() bool + func (m *Message) Marshal() (dAtA []byte, err error) + func (m *Message) MarshalTo(dAtA []byte) (int, error) + func (m *Message) Size() (n int) + func (m *Message) SizeUpperLimit() int + func (m *Message) Unmarshal(dAtA []byte) error + type MessageBatch struct + BinVer uint32 + DeploymentId uint64 + Requests []Message + SourceAddress string + func (m *MessageBatch) Marshal() (dAtA []byte, err error) + func (m *MessageBatch) MarshalTo(dAtA []byte) (int, error) + func (m *MessageBatch) Size() (n int) + func (m *MessageBatch) SizeUpperLimit() int + func (m *MessageBatch) Unmarshal(dAtA []byte) error + type MessageType int32 + const BatchedReadIndex + const CheckQuorum + const ConfigChangeEvent + const Election + const Heartbeat + const HeartbeatResp + const InstallSnapshot + const LeaderHeartbeat + const LeaderTransfer + const LocalTick + const LogQuery + const NoOP + const Ping + const Pong + const Propose + const Quiesce + const RateLimit + const ReadIndex + const ReadIndexResp + const Replicate + const ReplicateResp + const RequestPreVote + const RequestPreVoteResp + const RequestVote + const RequestVoteResp + const SnapshotReceived + const SnapshotStatus + const TimeoutNow + const Unreachable + func (x MessageType) String() string + type RaftDataStatus struct + Address string + AddressByNodeHostId bool + BinVer uint32 + DeploymentId uint64 + EntryBatchSize uint64 + HardHash uint64 + Hostname string + LogdbShardCount uint64 + LogdbType string + MaxSessionCount uint64 + StepWorkerCount uint64 + func (m *RaftDataStatus) Marshal() (dAtA []byte, err error) + func (m *RaftDataStatus) MarshalTo(dAtA []byte) (int, error) + func (m *RaftDataStatus) Size() (n int) + func (m *RaftDataStatus) Unmarshal(dAtA []byte) error + type ReadyToRead struct + Index uint64 + SystemCtx SystemCtx + type Snapshot struct + Checksum []byte + Dummy bool + FileSize uint64 + Filepath string + Files []*SnapshotFile + Imported bool + Index uint64 + Membership Membership + OnDiskIndex uint64 + ShardID uint64 + Term uint64 + Type StateMachineType + Witness bool + func (m *Snapshot) Load(c ICompactor) + func (m *Snapshot) Marshal() (dAtA []byte, err error) + func (m *Snapshot) MarshalTo(dAtA []byte) (int, error) + func (m *Snapshot) Ref() + func (m *Snapshot) Size() (n int) + func (m *Snapshot) Unmarshal(dAtA []byte) error + func (m *Snapshot) Unref() error + func (snapshot *Snapshot) Validate(fs vfs.IFS) bool + type SnapshotFile struct + FileId uint64 + FileSize uint64 + Filepath string + Metadata []byte + func (m *SnapshotFile) Filename() string + func (m *SnapshotFile) Marshal() (dAtA []byte, err error) + func (m *SnapshotFile) MarshalTo(dAtA []byte) (int, error) + func (m *SnapshotFile) Size() (n int) + func (m *SnapshotFile) Unmarshal(dAtA []byte) error + type SnapshotHeader struct + ChecksumType ChecksumType + CompressionType CompressionType + DataStoreSize uint64 + GitVersion string + HeaderChecksum []byte + PayloadChecksum []byte + SessionSize uint64 + UnreliableTime uint64 + Version uint64 + func (m *SnapshotHeader) Marshal() (dAtA []byte, err error) + func (m *SnapshotHeader) MarshalTo(dAtA []byte) (int, error) + func (m *SnapshotHeader) Size() (n int) + func (m *SnapshotHeader) Unmarshal(dAtA []byte) error + type State struct + Commit uint64 + Term uint64 + Vote uint64 + func (m *State) Marshal() (dAtA []byte, err error) + func (m *State) MarshalTo(dAtA []byte) (int, error) + func (m *State) Size() (n int) + func (m *State) SizeUpperLimit() int + func (m *State) Unmarshal(dAtA []byte) error + type StateMachineType int32 + const ConcurrentStateMachine + const OnDiskStateMachine + const RegularStateMachine + const UnknownStateMachine + func (x StateMachineType) String() string + type SystemCtx struct + High uint64 + Low uint64 + type Unmarshaler interface + Unmarshal func([]byte) error + type Update struct + CommittedEntries []Entry + DroppedEntries []Entry + DroppedReadIndexes []SystemCtx + EntriesToSave []Entry + FastApply bool + LastApplied uint64 + LeaderUpdate LeaderUpdate + LogQueryResult LogQueryResult + Messages []Message + MoreCommittedEntries bool + ReadyToReads []ReadyToRead + ReplicaID uint64 + ShardID uint64 + Snapshot Snapshot + UpdateCommit UpdateCommit + func (u *Update) HasUpdate() bool + func (u *Update) MarshalTo(buf []byte) (int, error) + func (u *Update) SizeUpperLimit() int + func (u *Update) Unmarshal(buf []byte) error + type UpdateCommit struct + LastApplied uint64 + Processed uint64 + ReadyToRead uint64 + StableLogTerm uint64 + StableLogTo uint64 + StableSnapshotTo uint64 Other modules containing this package github.com/foreeest/dragonboat/v2