record

package
v0.9.0 Latest Latest
Warning

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

Go to latest
Published: Sep 7, 2023 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Block

type Block struct {
	ID       uint64
	Endpoint string
}

type Eventbus

type Eventbus struct {
	Name string
	Logs []*Eventlog
}

func (*Eventbus) ReadableLog

func (b *Eventbus) ReadableLog() []*Eventlog

ReadableLog return all readable logs.

func (*Eventbus) WritableLog

func (b *Eventbus) WritableLog() []*Eventlog

WritableLog return all writable logs.

type Eventlog

type Eventlog struct {
	ID   uint64
	Mode LogMode
}

func (*Eventlog) Readable

func (l *Eventlog) Readable() bool

func (*Eventlog) Writable

func (l *Eventlog) Writable() bool

type LogMode

type LogMode uint32
const (
	PremWrite LogMode = 1 << 1
	PremRead  LogMode = 1 << 2
)
const (
	ModePerm LogMode = 07
)

func (LogMode) Perm

func (m LogMode) Perm() LogMode

func (LogMode) Readable

func (m LogMode) Readable() bool

func (LogMode) Writable

func (m LogMode) Writable() bool

type Segment

type Segment struct {
	ID               uint64
	StartOffset      int64
	EndOffset        int64
	Writable         bool
	FirstEventBornAt time.Time
	LastEventBornAt  time.Time

	Blocks        map[uint64]*Block
	LeaderBlockID uint64
}

func (*Segment) GetLeaderEndpoint

func (s *Segment) GetLeaderEndpoint() string

Jump to

Keyboard shortcuts

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