diff options
Diffstat (limited to 'modules/stats/stats.c')
-rw-r--r-- | modules/stats/stats.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/modules/stats/stats.c b/modules/stats/stats.c index deed9c94..596847d7 100644 --- a/modules/stats/stats.c +++ b/modules/stats/stats.c @@ -37,12 +37,17 @@ #define UPSTREAMS_COUNT 512 /* Size of recent upstreams */ #endif -/** @cond internal Fixed-size map of predefined metrics. */ +/** @cond internal Fixed-size map of predefined metrics. + * + * When changing the list, don't forget _parse_resolver_metrics() + * in ../../manager/knot_resolver_manager/statistics.py + */ #define CONST_METRICS(X) \ X(answer,total) X(answer,noerror) X(answer,nodata) X(answer,nxdomain) X(answer,servfail) \ X(answer,cached) X(answer,1ms) X(answer,10ms) X(answer,50ms) X(answer,100ms) \ X(answer,250ms) X(answer,500ms) X(answer,1000ms) X(answer,1500ms) X(answer,slow) \ X(answer,sum_ms) \ + X(answer,stale) \ X(answer,aa) X(answer,tc) X(answer,rd) X(answer,ra) X(answer, ad) X(answer,cd) \ X(answer,edns0) X(answer,do) \ X(query,edns) X(query,dnssec) \ @@ -303,6 +308,7 @@ static int collect(kr_layer_t *ctx) DEPRECATED use new names metric_answer_edns0 and metric_answer_do */ + stat_const_add(data, metric_answer_stale, param->stale_accounted); stat_const_add(data, metric_query_edns, knot_pkt_has_edns(param->answer)); stat_const_add(data, metric_query_dnssec, knot_pkt_has_dnssec(param->answer)); |