Documentation
¶
Overview ¶
Package metrics holds the rules for the metrics a mod declares in its manifest: which declarations a build may carry, which labels a call may name, and how each kind combines the values added to it.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func Find ¶
func Find(manifest *manifestpb.Manifest, name string) *metricspb.Metric
Find returns the metric named name that manifest declares, or nil.
func Labeled ¶
Labeled reports whether a call may label metric with label: one of its labels, or empty for a metric without labels.
func Validate ¶
func Validate(manifest *manifestpb.Manifest) error
Validate checks the metrics manifest declares.
Types ¶
type Tally ¶
type Tally struct {
// contains filtered or unexported fields
}
Tally keeps one player's totals of one mod's metrics.
func (*Tally) Totals ¶
func (t *Tally) Totals() *metricspb.MetricTotals
Totals returns the totals in name and label order.
Click to show internal directories.
Click to hide internal directories.