storage

package
v0.0.0-...-5a82b97 Latest Latest
Warning

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

Go to latest
Published: Feb 8, 2020 License: MIT Imports: 14 Imported by: 0

Documentation

Index

Constants

View Source
const (
	/*
		SSTableLevelMAJOR indicates the sstable is a major sstable, holding
		all stable sstable data from the point of the last major compaction.
	*/
	SSTableLevelMAJOR = iota

	/*
		SSTableLevelMINOR indicates a minor sstable, holding all changes which
		have undergone logsorting since the last minor compaction.
	*/
	SSTableLevelMINOR

	/*
		SSTableLevelJOURNAL indicates a simple journal file, sorted by update
		time.
	*/
	SSTableLevelJOURNAL
)

Variables

This section is empty.

Functions

func LookupInJournal

func LookupInJournal(parentCtx context.Context, path string, columns []string,
	kr *common.KeyRange, results chan *redcloud.ColumnFamily,
	errors chan error, done chan struct{})

LookupInJournal finds all records in the specified key range in the specified file matching the selected columns. Deadlines and cancellations from the context "ctx" are taken into account. Any results will be reported through the channel "results", errors will be reported through "errors", and "done" will be marked as soon as processing the file has completed.

columns is expected to be sorted (see sort.Strings).

func LookupInSstable

func LookupInSstable(parentCtx context.Context, path string, columns []string,
	kr *common.KeyRange, results chan *redcloud.ColumnFamily,
	errors chan error, done chan struct{})

LookupInSstable finds all records in the specified key range in the specified file matching the selected columns. Deadlines and cancellations from the context "ctx" are taken into account. Any results will be reported through the channel "results", errors will be reported through "errors", and "done" will be marked as soon as processing the file has completed.

columns is expected to be sorted (see sort.Strings).

func MakePath

func MakePath(instance, table, cf string, endkey []byte, when time.Time, level SSTableLevel) string

MakePath produces the full path name for a file containing data pertaining to the specified instance/table/column family/endkey/date/type tuple.

func MakePathPrefix

func MakePathPrefix(instance, table, cf string, endkey []byte) string

MakePathPrefix produces an appropriate path prefix for a file containing data pertaining to the specified instance/table/column family/endkey tuple.

func SSTableLevel2String

func SSTableLevel2String(level SSTableLevel) string

SSTableLevel2String expresses the name of the SSTableLevel as text.

Types

type SSTableLevel

type SSTableLevel int

SSTableLevel describes the level this sstable exists as. It is mostly used to find the appropriate file name.

Jump to

Keyboard shortcuts

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