logging2

package
v0.5.3 Latest Latest
Warning

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

Go to latest
Published: Mar 29, 2023 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const LOGCOMMIT = uint64(0)
View Source
const LOGEND = LOGMAXBLK + LOGSTART
View Source
const LOGMAXBLK = uint64(510)
View Source
const LOGSTART = uint64(1)

Variables

This section is empty.

Functions

This section is empty.

Types

type Log

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

func Init

func Init(logSz uint64) Log

func (Log) Append

func (log Log) Append(l []disk.Block) bool

func (Log) Logger

func (log Log) Logger()

func (Log) Read

func (log Log) Read() []disk.Block

type Txn

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

func Begin

func Begin(log *Log) Txn

XXX wait if cannot reserve space in log

func (Txn) Commit

func (txn Txn) Commit() bool

func (Txn) Read

func (txn Txn) Read(addr uint64) disk.Block

func (Txn) Write

func (txn Txn) Write(addr uint64, blk *disk.Block) bool

Jump to

Keyboard shortcuts

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