Hive
fix(server): skip large recent bucket backfills
GitHub issue · Closed
Source
tuist/tuist #11245
Updated
Jun 24, 2026
Domains
Kura
What changed
- Skip the historical backfill for the 500 and 750 test-case recent bucket aggregate tables in the ClickHouse migration.
- Keep creating the 500 and 750 aggregate tables and materialized views, so new test case runs will populate them going forward.
- Restore the legacy
TUIST_KURA_INTROSPECTION_CLIENT_IDandTUIST_KURA_INTROSPECTION_CLIENT_SECRETkeys in the server ExternalSecret template alongside the newerKURA_CONTROL_PLANE_*keys.
Why
The production deploy is still getting stuck in the migration hook. The 100 and 250 bucket backfills complete, but the 500 bucket historical backfill can still exceed ClickHouse’s memory cap even after the previous chunking changes. We do not need to force that larger historical backfill as part of the hotfix release; allowing those tables to populate from new data lets the deploy proceed without dropping the future-facing views.
The server rollout can also wedge because existing pods still reference the legacy Kura introspection env var names. The ExternalSecret currently renders only the newer control-plane aliases, so fresh pods can fail secret-key resolution before the release completes.
Impact
- The release should no longer spend migration-hook time trying to backfill the 500/750 historical buckets.
- The 500/750 bucket tables will be empty for historical data until we run a safer offline backfill later, but they will receive new rows through the materialized views.
- Existing and new server specs can resolve both Kura env var naming schemes during the rollout.
Validation
- Parsed and format-checked
server/priv/ingest_repo/migrations/20260515100000_create_test_case_runs_recent_buckets_per_case_mvs.exswith Elixir. - Rendered
infra/helm/tuist/templates/external-secrets.yamlfor production and confirmed the server ExternalSecret includes bothKURA_CONTROL_PLANE_*andTUIST_KURA_INTROSPECTION_*keys. - Ran
helm lintfor production values. - Ran
helm lintfor canary values. - Ran
git diff --check.