Documentation ¶
Index ¶
- type MemoryPartition
- func (m *MemoryPartition) Close() error
- func (p *MemoryPartition) Compact(w io.WriteSeeker) error
- func (m *MemoryPartition) Destroy() error
- func (p *MemoryPartition) ExclusiveHold()
- func (p *MemoryPartition) ExclusiveRelease()
- func (p *MemoryPartition) Filename() string
- func (p *MemoryPartition) HasMetric(source, metric string) bool
- func (p *MemoryPartition) HasSource(source string) bool
- func (p *MemoryPartition) Hold()
- func (p *MemoryPartition) InsertRows(rows []partition.Row) error
- func (p *MemoryPartition) MaxTimestamp() int64
- func (p *MemoryPartition) Metrics(source string) []string
- func (p *MemoryPartition) MinTimestamp() int64
- func (p *MemoryPartition) NewIterator(sourceName string, metricName string) (partition.Iterator, error)
- func (p *MemoryPartition) ReadOnly() bool
- func (p *MemoryPartition) Release()
- func (m *MemoryPartition) SetReadOnly()
- func (p *MemoryPartition) Sources() []string
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MemoryPartition ¶
type MemoryPartition struct {
// contains filtered or unexported fields
}
MemoryPartition is a partition that exists in-memory.
func NewMemoryPartition ¶
func NewMemoryPartition(WAL wal.WAL) *MemoryPartition
NewMemoryPartition creates a new MemoryPartition backed by WAL.
func RecoverMemoryPartition ¶
func RecoverMemoryPartition(WAL wal.WAL) (*MemoryPartition, error)
RecoverMemoryPartition recovers a MemoryPartition backed by WAL.
func (*MemoryPartition) Close ¶
func (m *MemoryPartition) Close() error
Closes sets the memory partition to read-only, releases resources, and closes its WAL.
func (*MemoryPartition) Compact ¶
func (p *MemoryPartition) Compact(w io.WriteSeeker) error
func (*MemoryPartition) Destroy ¶
func (m *MemoryPartition) Destroy() error
Destroy destroys the memory partition as well as its WAL.
func (*MemoryPartition) ExclusiveHold ¶
func (p *MemoryPartition) ExclusiveHold()
func (*MemoryPartition) ExclusiveRelease ¶
func (p *MemoryPartition) ExclusiveRelease()
func (*MemoryPartition) Filename ¶
func (p *MemoryPartition) Filename() string
func (*MemoryPartition) HasMetric ¶
func (p *MemoryPartition) HasMetric(source, metric string) bool
func (*MemoryPartition) HasSource ¶
func (p *MemoryPartition) HasSource(source string) bool
func (*MemoryPartition) Hold ¶
func (p *MemoryPartition) Hold()
func (*MemoryPartition) InsertRows ¶
func (p *MemoryPartition) InsertRows(rows []partition.Row) error
InsertRows inserts rows into the partition.
func (*MemoryPartition) MaxTimestamp ¶
func (p *MemoryPartition) MaxTimestamp() int64
func (*MemoryPartition) Metrics ¶
func (p *MemoryPartition) Metrics(source string) []string
func (*MemoryPartition) MinTimestamp ¶
func (p *MemoryPartition) MinTimestamp() int64
func (*MemoryPartition) NewIterator ¶
func (p *MemoryPartition) NewIterator(sourceName string, metricName string) (partition.Iterator, error)
NewIterator returns an Iterator for the partition that iterates over a sequence of points for the given source and metric.
func (*MemoryPartition) ReadOnly ¶
func (p *MemoryPartition) ReadOnly() bool
func (*MemoryPartition) Release ¶
func (p *MemoryPartition) Release()
func (*MemoryPartition) SetReadOnly ¶
func (m *MemoryPartition) SetReadOnly()
SetReadOnly sets the partition mode to read-only.
func (*MemoryPartition) Sources ¶
func (p *MemoryPartition) Sources() []string
Click to show internal directories.
Click to hide internal directories.