wal

package
v1.1.1 Latest Latest
Warning

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

Go to latest
Published: Aug 14, 2023 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const FileName = "/tmp/flydb/wal"

Variables

This section is empty.

Functions

This section is empty.

Types

type Wal

type Wal struct {
	// contains filtered or unexported fields
}

func New

func New() (*Wal, error)

func (*Wal) Delete

func (w *Wal) Delete(key []byte) error

func (*Wal) Get

func (w *Wal) Get(key []byte) error

func (*Wal) Put

func (w *Wal) Put(key []byte, value []byte) error

func (*Wal) Read

func (w *Wal) Read(index uint64) ([]byte, error)

func (*Wal) ReadLast

func (w *Wal) ReadLast() ([]byte, error)

func (*Wal) Update

func (w *Wal) Update(key []byte, value []byte) error

func (*Wal) Write

func (w *Wal) Write(data []byte) error

type WriteMessage

type WriteMessage struct {
	Key   []byte
	Value []byte
	Type  int //0: put, 1: get , 2: delete , 3: update
}

Jump to

Keyboard shortcuts

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