metadata

package
v0.34.0 Latest Latest
Warning

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

Go to latest
Published: Aug 31, 2021 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

View Source
const Type config.Type = "nginxreceiver"

Type is the component type name.

Variables

L contains the possible metric labels that can be used. L is an alias for Labels.

View Source
var LabelState = struct {
	Active  string
	Reading string
	Writing string
	Waiting string
}{
	"active",
	"reading",
	"writing",
	"waiting",
}

LabelState are the possible values that the label "state" can have.

View Source
var Labels = struct {
	// State (The state of a connection)
	State string
}{
	"state",
}

Labels contains the possible metric labels that can be used.

M contains a set of methods for each metric that help with manipulating those metrics. M is an alias for Metrics

View Source
var Metrics = &metricStruct{
	&metricImpl{
		"nginx.connections_accepted",
		func(metric pdata.Metric) {
			metric.SetName("nginx.connections_accepted")
			metric.SetDescription("The total number of accepted client connections")
			metric.SetUnit("connections")
			metric.SetDataType(pdata.MetricDataTypeSum)
			metric.Sum().SetIsMonotonic(true)
			metric.Sum().SetAggregationTemporality(pdata.AggregationTemporalityCumulative)
		},
	},
	&metricImpl{
		"nginx.connections_current",
		func(metric pdata.Metric) {
			metric.SetName("nginx.connections_current")
			metric.SetDescription("The current number of nginx connections by state")
			metric.SetUnit("connections")
			metric.SetDataType(pdata.MetricDataTypeGauge)
		},
	},
	&metricImpl{
		"nginx.connections_handled",
		func(metric pdata.Metric) {
			metric.SetName("nginx.connections_handled")
			metric.SetDescription("The total number of handled connections. Generally, the parameter value is the same as nginx.connections_accepted unless some resource limits have been reached (for example, the worker_connections limit).")
			metric.SetUnit("connections")
			metric.SetDataType(pdata.MetricDataTypeSum)
			metric.Sum().SetIsMonotonic(true)
			metric.Sum().SetAggregationTemporality(pdata.AggregationTemporalityCumulative)
		},
	},
	&metricImpl{
		"nginx.requests",
		func(metric pdata.Metric) {
			metric.SetName("nginx.requests")
			metric.SetDescription("Total number of requests made to the server since it started")
			metric.SetUnit("requests")
			metric.SetDataType(pdata.MetricDataTypeSum)
			metric.Sum().SetIsMonotonic(true)
			metric.Sum().SetAggregationTemporality(pdata.AggregationTemporalityCumulative)
		},
	},
}

Metrics contains a set of methods for each metric that help with manipulating those metrics.

Functions

This section is empty.

Types

type MetricIntf added in v0.20.0

type MetricIntf interface {
	Name() string
	New() pdata.Metric
	Init(metric pdata.Metric)
}

MetricIntf is an interface to generically interact with generated metric.

Jump to

Keyboard shortcuts

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