prometheus-net
27 строк · 1.3 Кб
1namespace Prometheus;2
3/// <summary>
4/// This class packages the options for creating metrics into a single class (with subclasses per metric type)
5/// for easy extensibility of the API without adding numerous method overloads whenever new options are added.
6/// </summary>
7public abstract class MetricConfiguration8{
9/// <summary>10/// NOTE: Only used by APIs that do not take an explicit labelNames value as input.11///12/// Names of all the label fields that are defined for each instance of the metric.13/// If null, the metric will be created without any instance-specific labels.14///15/// Before using a metric that uses instance-specific labels, .WithLabels() must be called to provide values for the labels.16/// </summary>17public string[]? LabelNames { get; set; }18
19/// <summary>20/// If true, the metric will not be published until its value is first modified (regardless of the specific value).21/// This is useful to delay publishing gauges that get their initial values delay-loaded.22///23/// By default, metrics are published as soon as possible - if they do not use labels then they are published on24/// creation and if they use labels then as soon as the label values are assigned.25/// </summary>26public bool SuppressInitialValue { get; set; }27}
28