Display runner dashboard ClickHouse features
What does this MR do and why?
This fix ensures the right elements are shown when ClickHouse is configured for the runners dashboard as well as making the dashboard layout when they are not.
When Clickhouse analytics is enabled, the following dashboard elements become available:
- Runner Usage CSV export
- Wait time to pick a job history chart
Changelog: fixed
Implementation Notes
- I replaced the CSS dashboard grid with a flex implementation, so when the CSV export panel is hidden, the rest of the content flows.
- I removed an outdated reference to the
clickhouse_ci_analytics
feature flag that has been removed in %16.8 in favor of the a check for ClickHouse to be configured - Renamed components
RunnerDashboardStatus...
toRunnerDashboardStat...
to matchGlSingleStat
nomenclature.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Screenshots or screen recordings
::Gitlab::ClickHouse.configured? == true |
::Gitlab::ClickHouse.configured? == false |
---|---|
How to set up and validate locally
We can test two states of the dashboard, with ClickHouse enabled and disabled
Disable Clickhouse
By default, your instance may not have Clickhouse configured.
-
Ensure you don't have a file at
config/click_house.yml
. -
You may restart if needed
Enable Clickhouse
- Locally, create a file called
config/click_house.yml
, with the following contents:
test:
main:
database: gitlab_clickhouse_test
url: 'http://localhost:8123'
username: default
development:
main:
database: gitlab_clickhouse_development
url: 'http://localhost:8123'
username: default
This will tell your instance to look for a clickhouse database at http://localhost:8123
. Even if you don't have one, the dashboard will show in the desired state (with an error at the top).
- Restart your instance (e.g.
gdk restart
)
Related to #428166 (closed)