Investigation: ClickHouse as engine for usage calculations
Context
Followup from #779 (closed). Please read through #779 (comment 1162735498) for context.
Task
We've identified ClickHouse as a good candidate to take over the usage calculations that are currently handled by the registry PostgreSQL database.
This issue is to dig deeper into the preliminary investigation and experiments done in #779 (closed) and:
- Confirm the overall technical feasibility;
- Identify any required changes to the registry DB, such as data de-normalization;
- Identify expected performance outcome (how much faster would it be compared with the current PostgreSQL approach).