Documentation
¶
Overview ¶
Package instrumentation defines primitives to support more observability throughout the constraint framework.
Index ¶
Constants ¶
View Source
const ( // TemplateScope means the stat is associated with a template. TemplateScope = "template" // ConstraintScope means the state is associated with a constraint. ConstraintScope = "constraint" // UnknownDescription is used when the description is not available. UnknownDescription = "unknown description" // EngineSourceType identifies the source type as an engine. EngineSourceType = "engine" )
Variables ¶
View Source
var RegoSource = Source{ Type: EngineSourceType, Value: schema.Name, }
RegoSource is the Source configuration for the Rego engine.
Functions ¶
This section is empty.
Types ¶
type Label ¶
type Label struct {
Name string `json:"name"`
Value interface{} `json:"value"`
}
Label is a name/value tuple to add metadata about a StatsEntry.
type Source ¶
Source is a special Stat level label of the form type/value that is meant to be used to identify where a Stat is coming from.
type Stat ¶
type Stat struct {
Name string `json:"name"`
Value interface{} `json:"value"`
Source Source `json:"source"`
}
Stat is a Name, Value, Description tuple that may contain metrics or aggregations of metrics.
type StatsEntry ¶
type StatsEntry struct {
// Scope is the level of granularity that the Stats
// were created at.
Scope string `json:"scope"`
// StatsFor is the specific kind of Scope type that Stats
// were created for.
StatsFor string `json:"statsFor"`
Stats []*Stat `json:"stats"`
Labels []*Label `json:"labels,omitempty"`
}
StatsEntry comprises of a generalized Key for all associated Stats.
Click to show internal directories.
Click to hide internal directories.