Internal

package
v0.0.0-...-72b2190 Latest Latest
Warning

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

Go to latest
Published: Sep 27, 2024 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func TestIndex

func TestIndex(t *testing.T)

func TestStoreAppendRead

func TestStoreAppendRead(t *testing.T)

func TestStoreClose

func TestStoreClose(t *testing.T)

Types

type Config

type Config struct {
	Segment struct {
		MaxStoreBytes uint64
		MaxIndexBytes uint64
		InitialOffset uint64
	}
}

type Log

type Log struct {
	Dir    string
	Config Config
	// contains filtered or unexported fields
}

func NewLog

func NewLog(dir string, c Config) (*Log, error)

START: newlog

func (*Log) Append

func (l *Log) Append(record *api.Record) (uint64, error)

START: append

func (*Log) Close

func (l *Log) Close() error

START: close

func (*Log) HighestOffset

func (l *Log) HighestOffset() (uint64, error)

func (*Log) LowestOffset

func (l *Log) LowestOffset() (uint64, error)

START: offsets

func (*Log) Read

func (l *Log) Read(off uint64) (*api.Record, error)

START: read

func (*Log) Reader

func (l *Log) Reader() io.Reader

START: reader

func (*Log) Remove

func (l *Log) Remove() error

func (*Log) Reset

func (l *Log) Reset() error

func (*Log) Truncate

func (l *Log) Truncate(lowest uint64) error

START: truncate

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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