LCOV - code coverage report
Current view: top level - zephyr/net/prometheus - label.h Hit Total Coverage
Test: new.info Lines: 4 7 57.1 %
Date: 2024-10-22 00:13:38

          Line data    Source code
       1           1 : /*
       2             :  * Copyright (c) 2024 Mustafa Abdullah Kus, Sparse Technology
       3             :  *
       4             :  * SPDX-License-Identifier: Apache-2.0
       5             :  */
       6             : 
       7             : #ifndef ZEPHYR_INCLUDE_PROMETHEUS_LABEL_H_
       8             : #define ZEPHYR_INCLUDE_PROMETHEUS_LABEL_H_
       9             : 
      10             : /**
      11             :  * @file
      12             :  *
      13             :  * @brief Prometheus label interface.
      14             :  *
      15             :  * @addtogroup prometheus
      16             :  * @{
      17             :  */
      18             : 
      19             : /* maximum length of label key */
      20           0 : #define MAX_PROMETHEUS_LABEL_KEY_LENGTH   16
      21             : /* maximum length of label value */
      22           0 : #define MAX_PROMETHEUS_LABEL_VALUE_LENGTH 16
      23             : /* maximum namber of labels per metric */
      24           0 : #define MAX_PROMETHEUS_LABELS_PER_METRIC  5
      25             : 
      26             : /**
      27             :  * @brief Prometheus label definition.
      28             :  *
      29             :  * This structure defines a Prometheus label.
      30             :  */
      31           1 : struct prometheus_label {
      32             :         /** Prometheus metric label key */
      33           1 :         char key[MAX_PROMETHEUS_LABEL_KEY_LENGTH];
      34             :         /** Prometheus metric label value */
      35           1 :         char value[MAX_PROMETHEUS_LABEL_VALUE_LENGTH];
      36             : };
      37             : 
      38             : /**
      39             :  * @}
      40             :  */
      41             : 
      42             : #endif /* ZEPHYR_INCLUDE_PROMETHEUS_LABEL_H_ */

Generated by: LCOV version 1.14