config

package
v4.5.2003+incompatible Latest Latest
Warning

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

Go to latest
Published: Jun 29, 2020 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	Units []Unit `mapstructure:"units"`

	// enum table definition
	MetricType  map[string]datahub_common.MetricType                  `mapstructure:"metricType"`
	Scope       map[string]datahub_schemas.Scope                      `mapstructure:"scope"`
	Aggregation map[string]datahub_common.TimeRange_AggregateFunction `mapstructure:"aggregation"`
}

func (*Config) GetUnits

func (cfg *Config) GetUnits() []Unit

func (*Config) Init

func (cfg *Config) Init()

api proto enum mapping

type Unit

type Unit struct {
	Enabled        bool                        `mapstructure:"enabled"`
	Predictor      string                      `mapstructure:"predictor"`
	ScopeStr       string                      `mapstructure:"scope"`
	Scope          datahub_schemas.Scope       `mapstructure:"-"`
	Category       string                      `mapstructure:"category"`
	Type           string                      `mapstructure:"type"`
	Granularities  []string                    `mapstructure:"granularities"`
	MetricTypeStrs []string                    `mapstructure:"metricTypes"`
	Metric         metricSeriesMeta            `mapstructure:"metric"`
	Prediction     predictSeriesMeta           `mapstructure:"prediction"`
	IDKeys         []string                    `mapstructure:"idKeys"`
	Measurement    string                      `mapstructure:"measurement"`
	UnitValueKeys  *unitValueKeys              `mapstructure:"valueKeys"`
	UnitParameters *unitParameters             `mapstructure:"parameters"`
	MetricTypes    []datahub_common.MetricType `mapstructure:"-"`
}

Jump to

Keyboard shortcuts

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