[GO][EDIT] Added comment for description()

This commit is contained in:
BuildTools
2020-12-02 03:05:03 +01:00
parent bc05385e81
commit b55e137dba

View File

@@ -25,6 +25,11 @@ func descriptionForPropertyNameHelpText(prefix, property string, labelNames []st
) )
} }
// Create a description for a Prometheus metric
// prefix: metric prefix
// name: metric name
// helpText: a string to describe the metric
// labelNames:
func description(prefix, name, helpText string, labelNames []string) *prometheus.Desc { func description(prefix, name, helpText string, labelNames []string) *prometheus.Desc {
return prometheus.NewDesc( return prometheus.NewDesc(
prometheus.BuildFQName(namespace, prefix, name), prometheus.BuildFQName(namespace, prefix, name),