Closed jaypha closed 2 years ago
On second inspection, the period code is specific to the database collector, and so in the interests of keeping metrics 'collector blind', that code should say within the database collector. So new priorities
period_from_interval()
to database collector plugin.
Not all metrics will be defined within the tool_cloudmetrics plugin. Metrics defined in other plugins will use their own config namespace. Any getting and setting of configs should be done through the metric classes (derived from
metric\base
).In particular:
metric\base
. https://github.com/catalyst/moodle-tool_cloudmetrics/blob/d04c2b3ceef133320671dacebb5bfbc367749e0f/classes/metric/lib.php#L35metric\<metricname>::get_frequency()
https://github.com/catalyst/moodle-tool_cloudmetrics/blob/d04c2b3ceef133320671dacebb5bfbc367749e0f/classes/metric/lib.php#L36