Documentation ¶
Index ¶
- func GenerateMetricsReport(metricsCollections Collections) *proto.MetricsReport
- func GetCalculationMap() map[string]string
- func NewStatsEntity(dims []*proto.Dimension, samples []*proto.SimpleMetric) *proto.StatsEntity
- type Collections
- type Collector
- type CommonDim
- type MetricsHandler
- type NginxCollectorConfig
- type NginxSource
- type PerDimension
- type Source
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GenerateMetricsReport ¶
func GenerateMetricsReport(metricsCollections Collections) *proto.MetricsReport
func GetCalculationMap ¶ added in v2.20.0
func NewStatsEntity ¶
func NewStatsEntity(dims []*proto.Dimension, samples []*proto.SimpleMetric) *proto.StatsEntity
Types ¶
type Collections ¶
type Collections struct { Count int // this is the number of collections run. Will use this to calculate the average. Data map[string]PerDimension }
func SaveCollections ¶
func SaveCollections(metricsCollections Collections, reports ...*proto.MetricsReport) Collections
SaveCollections loops through one or more reports and get all the raw metrics for the Collections Note this function operate on the Collections struct data directly.
type CommonDim ¶
type CommonDim struct {
SystemId, Hostname, InstanceTags, InstanceGroup,
DisplayName, NginxId string
PublishedAPI, NginxType, NginxBuild, NginxVersion,
NginxBinPath, NginxConfPath string
NginxAccessLogPaths []string
}
CommonDim is the set of dimensions that apply to all metrics
func NewCommonDim ¶
func (*CommonDim) ToDimensions ¶
ToDimensions returns the set of common agent dimensions Ensures dimensions are generated in the same order every time, as required by control plane
type MetricsHandler ¶
type NginxCollectorConfig ¶
type NginxSource ¶
type NginxSource interface { Collect(ctx context.Context, wg *sync.WaitGroup, m chan<- *proto.StatsEntity) Update(dimensions *CommonDim, collectorConf *NginxCollectorConfig) Stop() }
type PerDimension ¶
Click to show internal directories.
Click to hide internal directories.