Skip to content

feat(clickhouse): add txgen_runs.force_display - #355

Open
shekhirin wants to merge 2 commits into
mainfrom
shekhirin/force-display
Open

shekhirin wants to merge 2 commits into
mainfrom
shekhirin/force-display

Conversation

@shekhirin

Copy link
Copy Markdown
Member

Adds force_display Bool DEFAULT false to txgen_runs. The perf dashboards show a run with it set even when it isn't a scheduled nightly (tempoxyz/tempo-apps-internal#204). Writers never set it, so no txgen change is needed; operators flag runs with ALTER TABLE txgen_runs UPDATE force_display = true WHERE run_id = '<run_id>'.

Already applied to the production cluster (same statement), so this records the schema change.

@claude claude Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. The latest commit fixes the earlier apply.sh problem: the example statement in the header comment no longer ends in ;, so migration 011 is now sent as one statement.

What was reviewed:

  • Traced how apply.sh splits 011: lines 1-8 go out as one ALTER, and nothing in a comment line ends a statement early.
  • ADD COLUMN IF NOT EXISTS ... Bool DEFAULT false COMMENT '...' can be re-run, which matches the other additive migrations (004, 010).
  • Writers insert into txgen_runs with FORMAT JSONEachRow (crates/bench-core/src/clickhouse.rs). The new column is omitted from those inserts, so it takes its default of false and existing writers keep working.
Extended reasoning...

The change adds one 8-line ClickHouse migration, scripts/clickhouse/011_txgen_runs_force_display.sql, which adds a nullable-free Bool column with a default to txgen_runs. It touches no security-sensitive surface such as auth, injection paths or data exposure. The only earlier objection was my own, that the comment line ending in ; broke apply.sh, and commit a5f5898 fixed it. The repo has no CODEOWNERS file, and the timeline shows no outstanding reviews from anyone else. The migration follows the same idempotent pattern as the existing additive migrations.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant