MCPcopy
hub / github.com/prometheus/client_golang / Desc

Method Desc

prometheus/metric.go:39–39  ·  view source on GitHub ↗

Desc returns the descriptor for the Metric. This method idempotently returns the same descriptor throughout the lifetime of the Metric. The returned descriptor is immutable by contract. A Metric unable to describe itself must return an invalid descriptor (created with NewInvalidDesc).

()

Source from the content-addressed store, hash-verified

37 // unable to describe itself must return an invalid descriptor (created
38 // with NewInvalidDesc).
39 Desc() *Desc
40 // Write encodes the Metric into a "Metric" Protocol Buffer data
41 // transmission object.
42 //

Callers 15

DescribeMethod · 0.65
TestBatchHistogramFunction · 0.65
DescMethod · 0.65
TestGoCollectorMemStatsFunction · 0.65
TestConstNativeHistogramFunction · 0.65
processMetricFunction · 0.65

Implementers 14

valueFuncprometheus/value.go
constMetricprometheus/value.go
batchHistogramprometheus/go_collector_latest.go
wrappingMetricprometheus/wrap.go
counterprometheus/counter.go
Infoprometheus/example_metricvec_test.go
invalidMetricprometheus/metric.go
histogramprometheus/histogram.go
constHistogramprometheus/histogram.go
constNativeHistogramprometheus/histogram.go
summaryprometheus/summary.go
noObjectivesSummaryprometheus/summary.go

Calls

no outgoing calls

Tested by 10

TestBatchHistogramFunction · 0.52
TestGoCollectorMemStatsFunction · 0.52
TestConstNativeHistogramFunction · 0.52
TestGaugeFuncFunction · 0.52