File tree Expand file tree Collapse file tree 2 files changed +13
-2
lines changed
include/zephyr/net/prometheus
subsys/net/lib/prometheus Expand file tree Collapse file tree 2 files changed +13
-2
lines changed Original file line number Diff line number Diff line change 16
16
* @{
17
17
*/
18
18
19
- /* maximum namber of labels per metric */
20
- #define MAX_PROMETHEUS_LABELS_PER_METRIC 5
19
+ #if defined(CONFIG_PROMETHEUS )
20
+ /** Maximum number of labels per metric */
21
+ #define MAX_PROMETHEUS_LABELS_PER_METRIC CONFIG_PROMETHEUS_LABEL_MAX_COUNT
22
+ #else
23
+ #define MAX_PROMETHEUS_LABELS_PER_METRIC 1
24
+ #endif /* CONFIG_PROMETHEUS */
21
25
22
26
/**
23
27
* @brief Prometheus label definition.
Original file line number Diff line number Diff line change @@ -10,6 +10,13 @@ menuconfig PROMETHEUS
10
10
11
11
if PROMETHEUS
12
12
13
+ config PROMETHEUS_LABEL_MAX_COUNT
14
+ int "Max label count in metric"
15
+ range 1 8
16
+ default 1
17
+ help
18
+ Specify how many labels can be attached to a metric.
19
+
13
20
module = PROMETHEUS
14
21
module-dep = NET_LOG
15
22
module-str = Log level for PROMETHEUS
You can’t perform that action at this time.
0 commit comments