mstore

package
v0.0.0-...-2cbbd22 Latest Latest
Warning

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

Go to latest
Published: Oct 1, 2025 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ModeGauge     = 0x47415547
	ModeCounter   = 0x434f554e
	ModeIncrement = 0x494e4352
	ModeText      = 0x54455854
	ModeBinary    = 0x44415441

	AggregateMinimum    = 1
	AggregateMaximum    = 2
	AggregateSum        = 3
	AggregateAverage    = 4
	AggregateFirst      = 5
	AggregateLast       = 6
	AggregateHistogram  = 7
	AggregatePercentile = 8
	AggregateRaw        = 9

	MaxColumns = 128
)

Variables

View Source
var (
	ModeNames = map[int64]string{
		ModeGauge:     "gauge",
		ModeCounter:   "counter",
		ModeIncrement: "increment",
		ModeText:      "text",
		ModeBinary:    "binary",
	}
	ModeIndexes = map[string]int64{
		"gauge":     ModeGauge,
		"counter":   ModeCounter,
		"increment": ModeIncrement,
		"text":      ModeText,
		"binary":    ModeBinary,
	}
	AggregateNames = map[int64]string{
		AggregateMinimum:    "minimum",
		AggregateMaximum:    "maximum",
		AggregateSum:        "sum",
		AggregateAverage:    "average",
		AggregateFirst:      "first",
		AggregateLast:       "last",
		AggregateHistogram:  "histogram",
		AggregatePercentile: "percentile",
		AggregateRaw:        "raw",
	}
	AggregateIndexes = map[string]int64{
		"min":        AggregateMinimum,
		"minimum":    AggregateMinimum,
		"max":        AggregateMaximum,
		"maximum":    AggregateMaximum,
		"sum":        AggregateSum,
		"avg":        AggregateAverage,
		"average":    AggregateAverage,
		"first":      AggregateFirst,
		"last":       AggregateLast,
		"hist":       AggregateHistogram,
		"histogram":  AggregateHistogram,
		"pct":        AggregatePercentile,
		"percentile": AggregatePercentile,
		"raw":        AggregateRaw,
	}
)

Functions

This section is empty.

Types

type Column

type Column struct {
	Mode        int64
	Size        int64
	Description string
	// contains filtered or unexported fields
}

type Store

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

func NewStore

func NewStore(prefix string, readonly ...bool) (store *Store, err error)

func (*Store) Delete

func (s *Store) Delete(name string) error

func (*Store) Get

func (s *Store) Get(start, end time.Time, interval int64, names map[string][][]int64) (result map[string]any)

func (*Store) List

func (s *Store) List(prefix string) (names []string)

func (*Store) Metric

func (s *Store) Metric(name string) *metric

func (*Store) Rename

func (s *Store) Rename(from, to string) error

func (*Store) Trim

func (s *Store) Trim(name string, start, end time.Time) error

Directories

Path Synopsis
cmd
mstore command

Jump to

Keyboard shortcuts

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