Documentation
¶
Index ¶
Constants ¶
View Source
const ( SstMagic = uint64(0xe489f8a9d479536b) // MaxSstKeySize is the max encoded keysize in an SST. // Slightly larger than DB MaxKeySize due to additional data. MaxSstKeySize = 8*1024 + 16 )
Variables ¶
View Source
var ( ErrNotFound = errors.New("not found") ErrCorruption = errors.New("corruption detected") )
Functions ¶
This section is empty.
Types ¶
type Cache ¶
type Cache struct {
// contains filtered or unexported fields
}
Cache is a cache of key -> bytes. Implements a segmented LRU algorithm.
type Iter ¶
type Iter struct {
// contains filtered or unexported fields
}
type Iterator ¶
type Iterator interface {
// Key returns the current key.
Key() string
// Value returns the current value. Callers should not modify the returned value.
// Returned value is only valid until the next call to Next.
Value() []byte
// Next advances the iterator. Returns whether there is another key/value.
Next() bool
// Close closes the iterator.
Close()
}
Iterator is an iterator over keys and values. Iterators MUST be closed when done.
type Reader ¶
type Reader struct {
// contains filtered or unexported fields
}
Reader is an SSTable reader. Threadsafe.
Click to show internal directories.
Click to hide internal directories.