From: Ulrich Wisser Date: Tue, 17 Jul 2018 20:46:54 +0000 (-0400) Subject: expose stats.upstreams as web api /upstreams X-Git-Tag: v3.2.0~11^2~13 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=fb2513e3e073acfd7b377eeedef8f0c212208f2e;p=thirdparty%2Fknot-resolver.git expose stats.upstreams as web api /upstreams --- diff --git a/modules/http/prometheus.lua b/modules/http/prometheus.lua index cf76ef4cf..cff4050df 100644 --- a/modules/http/prometheus.lua +++ b/modules/http/prometheus.lua @@ -164,7 +164,8 @@ M.deinit = snapshot_end M.endpoints = { ['/stats'] = {'application/json', getstats, stream_stats}, ['/frequent'] = {'application/json', function () return stats.frequent() end}, + ['/upstreams'] = {'application/json', function () return stats.upstreams() end}, ['/metrics'] = {'text/plain; version=0.0.4', serve_prometheus}, } -return M \ No newline at end of file +return M