kubernetesk8s.io/kubernetes/pkg/kubelet/server/metrics Index | Files

package metrics

import "k8s.io/kubernetes/pkg/kubelet/server/metrics"

Index

Variables

var (
	// HTTPRequests tracks the number of the http requests received since the server started.
	HTTPRequests = metrics.NewCounterVec(
		&metrics.CounterOpts{
			Subsystem:      kubeletSubsystem,
			Name:           "http_requests_total",
			Help:           "Number of the http requests received since the server started",
			StabilityLevel: metrics.ALPHA,
		},

		[]string{"method", "path", "server_type", "long_running"},
	)
	// HTTPRequestsDuration tracks the duration in seconds to serve http requests.
	HTTPRequestsDuration = metrics.NewHistogramVec(
		&metrics.HistogramOpts{
			Subsystem: kubeletSubsystem,
			Name:      "http_requests_duration_seconds",
			Help:      "Duration in seconds to serve http requests",

			Buckets:        metrics.DefBuckets,
			StabilityLevel: metrics.ALPHA,
		},
		[]string{"method", "path", "server_type", "long_running"},
	)
	// HTTPInflightRequests tracks the number of the inflight http requests.
	HTTPInflightRequests = metrics.NewGaugeVec(
		&metrics.GaugeOpts{
			Subsystem:      kubeletSubsystem,
			Name:           "http_inflight_requests",
			Help:           "Number of the inflight http requests",
			StabilityLevel: metrics.ALPHA,
		},
		[]string{"method", "path", "server_type", "long_running"},
	)
)

Functions

func Register

func Register()

Register all metrics.

func SinceInSeconds

func SinceInSeconds(start time.Time) float64

SinceInSeconds gets the time since the specified start in seconds.

Source Files

metrics.go

Version
v1.19.0-beta.0
Published
May 19, 2020
Platform
js/wasm
Imports
4 packages
Last checked
12 minutes ago

Tools for package owners.