Expose VSD distinct contributor counts via GraphQL
What does this MR do and why?
This MR adds the ClickHouse-based contributors count metric to the valueStreamDashboardUsageOverview
GraphQL query. It's only available for a few groups on SaaS until the rollout epic is done: &11732
How to set up and validate locally
Enable FFs:
Feature.enable(:clickhouse_data_collection)
Feature.enable(:event_sync_worker_for_click_house)
- Ensure that you're on ultimate
- Ensure that CH is configured: https://docs.gitlab.com/ee/development/database/clickhouse/clickhouse_within_gitlab.html
- For prepping the DB schema you can invoke:
bundle exec rake gitlab:clickhouse:migrate
- If your GDK is seeded, then you probably have some events records, you can sync them to CH:
ClickHouse::EventsSyncWorker.new.perform
- Run the following GraphQL query:
{
group(fullPath: "gitlab-org") {
id
valueStreamDashboardUsageOverview(
identifier: CONTRIBUTORS
timeframe: {start: "2023-12-01", end: "2023-12-30"}
) {
identifier
count
recordedAt
}
}
}
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Related to #432838 (closed)
Edited by Adam Hegyi