Code

src/daemon/utils_match.[ch]: Rename UTILS_MATCH_CF_GAUGE_LATENCY to UTILS_MATCH_CF_GA...
authorFlorian Forster <octo@collectd.org>
Sun, 27 Nov 2016 07:02:39 +0000 (08:02 +0100)
committerFlorian Forster <octo@collectd.org>
Sun, 27 Nov 2016 07:02:39 +0000 (08:02 +0100)
src/daemon/utils_match.c
src/daemon/utils_match.h
src/daemon/utils_tail_match.c
src/tail.c

index 98d9311641c394a5bef6a66bfa6b28b33e3cd78a..d1be244eb2d4b77d59b27d39f878bf721c64f6ee 100644 (file)
@@ -99,7 +99,7 @@ static int default_callback (const char __attribute__((unused)) *str,
     if (matches[1] == endptr)
       return (-1);
 
-    if (data->ds_type & UTILS_MATCH_CF_GAUGE_LATENCY)
+    if (data->ds_type & UTILS_MATCH_CF_GAUGE_DIST)
     {
       latency_counter_add(data->latency, DOUBLE_TO_CDTIME_T(value));
       data->values_num++;
@@ -299,7 +299,7 @@ cu_match_t *match_create_simple (const char *regex,
   user_data->ds_type = match_ds_type;
 
   if ((match_ds_type & UTILS_MATCH_DS_TYPE_GAUGE)
-      && (match_ds_type & UTILS_MATCH_CF_GAUGE_LATENCY))
+      && (match_ds_type & UTILS_MATCH_CF_GAUGE_DIST))
   {
     user_data->latency = latency_counter_create();
     if (user_data->latency == NULL)
index c44bce09e8765bb6cdeabde202ab7af092ef4f8c..7b263d7776ef0b63c3e96cad965a527daeb6b6a0 100644 (file)
@@ -48,7 +48,7 @@
 #define UTILS_MATCH_CF_GAUGE_INC     0x10
 #define UTILS_MATCH_CF_GAUGE_ADD     0x20
 #define UTILS_MATCH_CF_GAUGE_PERSIST 0x40
-#define UTILS_MATCH_CF_GAUGE_LATENCY 0x80
+#define UTILS_MATCH_CF_GAUGE_DIST    0x80
 
 #define UTILS_MATCH_CF_COUNTER_SET   0x01
 #define UTILS_MATCH_CF_COUNTER_ADD   0x02
index b52a319bb133ed13afce5977d8b5e67274e977c7..a0cbc11df63ffecbdee60d8a18714d8a14bfdd22 100644 (file)
@@ -305,7 +305,7 @@ int tail_match_add_match_simple (cu_tail_match_t *obj,
   user_data->interval = interval;
 
   if ((ds_type & UTILS_MATCH_DS_TYPE_GAUGE)
-      && (ds_type & UTILS_MATCH_CF_GAUGE_LATENCY))
+      && (ds_type & UTILS_MATCH_CF_GAUGE_DIST))
   {
     status = latency_config_copy(&user_data->latency_config, latency_cfg);
     if (status != 0)
index c1e556214894d6055db91d736f39b0cbd58ac1b0..ff76b7259e735c47efb7326f73b49d1e03d914ef 100644 (file)
@@ -95,7 +95,7 @@ static int ctail_config_add_match_dstype (ctail_config_match_t *cm,
   }
   else if (strcasecmp ("Distribution", ds_type) == 0)
   {
-    cm->flags = UTILS_MATCH_DS_TYPE_GAUGE | UTILS_MATCH_CF_GAUGE_LATENCY;
+    cm->flags = UTILS_MATCH_DS_TYPE_GAUGE | UTILS_MATCH_CF_GAUGE_DIST;
 
     int status = latency_config (&cm->latency, ci, "tail");
     if (status != 0)