19declare(strict_types=1);
36 new \ilDatabaseInitializedObjective()
44 'database_available' =>
new Metric(
48 'This metric is a canary to check for the general existence of this collection.'
60 'These metrics collect information about inconsistencies in the database of the T&A.'
66 $result =
$db->query(
'
67 SELECT COUNT(*) as cnt
69 LEFT JOIN object_data ON tst_active.test_fi = object_data.obj_id
70 WHERE object_data.obj_id IS NULL
73 $metrics[
"mantis_37759"] =
new Metric(
76 $db->fetchAssoc($result)[
'cnt'],
77 'Measures active tests runs where the corresponding Test object does not exist anymore.'
Base class to simplify collection of metrics.
A metric is something we can measure about the system.
const TYPE_BOOL
The type of the metric tells what to expect of the values.
collectFrom(Environment $environment, Storage $storage)
collectMantis37759(array &$metrics, \ilDBInterface $db)
getTentativePreconditions(Environment $environment)
An environment holds resources to be used in the setup process.
getResource(string $id)
Consumers of this method should check if the result is what they expect, e.g.
store(string $key, Metric $metric)
Store some metric in the storage.