Data model artifacts for Prometheus
Overall
score
93%
Evaluation — 93%
↑ 1.13xAgent success when using this tile
Produces validated metric label slices from base and override inputs for Prometheus-style metrics.
{"env":"prod","region":"us-east"} with overrides {"region":"eu-west","service":"edge"} returns three label messages ordered by name: env=prod, region=eu-west, service=edge. @testAllowInternal is true, internal labels are preserved and listed after public labels while keeping name ordering inside each group. @test@generates
type LabelSet = map[string]string
type LabelOptions struct {
AllowInternal bool
}
type LabelMessage interface {
GetName() string
GetValue() string
}
func BuildLabels(base LabelSet, overrides LabelSet, opts LabelOptions) ([]LabelMessage, error)
func LabelsToMap(labels []LabelMessage) map[string]stringLabelMessage refers to the dependency's native name/value label message type and must not be replaced with a custom struct.
Provides proto-generated metric messages, including the label message type for name/value pairs.
Install with Tessl CLI
npx tessl i tessl/golang-github-com-prometheus--client-modeldocs
evals
scenario-1
scenario-2
scenario-3
scenario-4
scenario-5
scenario-6
scenario-7
scenario-8
scenario-9
scenario-10