10 Commits

Author SHA1 Message Date
Jimmy Berry
da5bfafb42 metrics: provide release metrics ingestion and dashboard. 2018-03-09 00:34:01 -06:00
Jimmy Berry
76ac5d6b2e metrics: ingest_release_schedule(): disable for Tumbleweed until #1250. 2018-02-19 14:40:17 -06:00
Jimmy Berry
f0fee5ec8d metrics: update Leap config key to match osclib/conf post #1386. 2018-02-19 14:39:44 -06:00
Jimmy Berry
1eba364ef8 metrics: provide --wipe-cache option. 2018-01-10 20:11:46 -06:00
Jimmy Berry
26883b12d2 metrics: rework to store points as named tuple and write in batches.
Savings of around 400MB per 10,000 requests. Using a named tuple was the
original approach for this reason, but the influxdb interface requires
dict()s and it seemed silly to spend time converting them. Additionally,
influxdb client already does batching.

Unfortunately, with the amount of data processed for Factory that will
continue to grow this approach is necessary. The dict() final structures
are buffered up to ~1000 before being written and released. Another
benefit of the batching is that influxdb does not allocate memory for the
entire incoming batch.
2017-11-09 16:17:57 -06:00
Jimmy Berry
8a87becd55 metrics: rework request pagination to provide as generator.
This prevents the memory required to process to be enough to load all
parsed request element trees at once. Instead only one page of requests
is loaded at a time and the memory freed after processed. The end result
is the memory consumption reduced by just over 20% (current Factory drops
by around 2.5GB).
2017-11-09 16:17:25 -06:00
Jimmy Berry
ab569dfab8 metrics: call ET.clear() to release unneeded memory used by search result.
Roughly 1800MB per 10,000 requests saved.
2017-11-09 16:17:25 -06:00
Jimmy Berry
d0c298246e metrics: prefix release schedule file with source dir path.
Otherwise, when deployed via package and run via /usr/bin the files are
not found.
2017-11-08 16:43:07 -06:00
d1c4801578 Another set of low-noise flake8 cleanups 2017-10-20 20:46:44 +02:00
Jimmy Berry
cb24f27eec Initial metrics ingestion, processing, write to influxdb, and grafana dashboards.
A lot of room for improvement and additional metrics that can be extracted.
Including non-final state requests would allow for analyzing the current
staging state instead of only historical state. Additionally, the current
state can be used to present an activity log.

Handling incremental updates is non-trivial given the deltas are evaluated
and stored in sum state. A few possible approaches, but likely not worth
the hassle given the relatively short processing time and infrequent desire
to update data (daily at minimum).
2017-10-06 16:08:33 -05:00