Commit 694704b2 authored by Dominik Hebeler's avatar Dominik Hebeler

switched metric to gauge

parent 689ac9f3
......@@ -122,9 +122,9 @@ class MetaGerSearch extends Controller
dd($timings);
}
\Prometheus\CollectorRegistry::getDefault()
->getOrRegisterCounter('metager', 'result_counter', 'counts total number of returned results')
->incBy(sizeof($metager->getResults()));
$registry = \Prometheus\CollectorRegistry::getDefault();
$gauge = $registry->getOrRegisterGauge('metager', 'result_gauge', 'counts total number of returned results');
$gauge->set(sizeof($metager->getResults()));
return $resultpage;
}
......@@ -205,10 +205,6 @@ class MetaGerSearch extends Controller
}
}
\Prometheus\CollectorRegistry::getDefault()
->getOrRegisterCounter('metager', 'result_counter', 'counts total number of returned results')
->incBy($newResults);
$finished = true;
foreach ($engines as $engine) {
if (!$engine->loaded) {
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment