metrics

package
v1.0.0 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2024 License: Apache-2.0 Imports: 1 Imported by: 120

Documentation

Overview

Deprecated: This package is intended for older projects transitioning from OPA v0.x and will remain for the lifetime of OPA v1.x, but its use is not recommended. For newer features and behaviours, such as defaulting to the Rego v1 syntax, use the corresponding components in the github.com/open-policy-agent/opa/v1 package instead. See https://www.openpolicyagent.org/docs/latest/v0-compatibility/ for more information.

Package metrics contains helpers for performance metric management inside the policy engine.

Index

Constants

View Source
const (
	BundleRequest       = v1.BundleRequest
	ServerHandler       = v1.ServerHandler
	ServerQueryCacheHit = v1.ServerQueryCacheHit
	SDKDecisionEval     = v1.SDKDecisionEval
	RegoQueryCompile    = v1.RegoQueryCompile
	RegoQueryEval       = v1.RegoQueryEval
	RegoQueryParse      = v1.RegoQueryParse
	RegoModuleParse     = v1.RegoModuleParse
	RegoDataParse       = v1.RegoDataParse
	RegoModuleCompile   = v1.RegoModuleCompile
	RegoPartialEval     = v1.RegoPartialEval
	RegoInputParse      = v1.RegoInputParse
	RegoLoadFiles       = v1.RegoLoadFiles
	RegoLoadBundles     = v1.RegoLoadBundles
	RegoExternalResolve = v1.RegoExternalResolve
)

Well-known metric names.

Variables

This section is empty.

Functions

func Statistics added in v0.31.0

func Statistics(num ...int64) interface{}

Types

type Counter added in v0.7.0

type Counter = v1.Counter

Counter defines the interface for a monotonic increasing counter.

type Histogram added in v0.7.0

type Histogram = v1.Histogram

Histogram defines the interface for a histogram with hardcoded percentiles.

type Info added in v0.14.0

type Info = v1.Info

Info contains attributes describing the underlying metrics provider.

type Metrics

type Metrics = v1.Metrics

Metrics defines the interface for a collection of performance metrics in the policy engine.

func New

func New() Metrics

New returns a new Metrics object.

type Timer

type Timer = v1.Timer

Timer defines the interface for a restartable timer that accumulates elapsed time.

type TimerMetrics added in v0.31.0

type TimerMetrics = v1.TimerMetrics

Jump to

Keyboard shortcuts

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