Skip to content

Add read-checksums command to clickhouse-disks - #106901

Merged
asya-ch merged 15 commits into
masterfrom
asya/checksums
Jun 18, 2026
Merged

asya-ch merged 15 commits into
masterfrom
asya/checksums

Conversation

@asya-ch

@asya-ch asya-ch commented Jun 9, 2026 •

Copy link
Copy Markdown
Collaborator

Changelog category (leave one):

  • New Feature

Changelog entry (a [user-readable short description])

Add read-checksums command to clickhouse-disks. It reads the checksums.txt file of a MergeTreeDataPart and prints it as a human-readable, tab-separated table.

Version info

  • Merged into: 26.6.1.1000

@clickhouse-gh

clickhouse-gh Bot commented Jun 9, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [9988ae4]

Summary: ❌

job_name test_name status info comment
Stress test (arm_tsan) FAIL
Logical error: Distributed task iterator is not initialized (STID: 4662-3e65) FAIL cidb, issue ISSUE CREATED
Finish Workflow FAIL
python3 ./ci/jobs/scripts/workflow_hooks/pr_body_check.py FAIL IGNORED

AI Review

Summary

This PR adds read-checksums to clickhouse-disks, registers it, documents it, and adds a stateless test for reading a MergeTree part checksums.txt. The code path looks reasonable after the earlier fixes, but the PR metadata still needs a small template fix before approval.

PR Metadata
  • Changelog category: New Feature is correct for adding a new clickhouse-disks command.
  • Changelog entry: required for New Feature, but the current header is truncated as ### Changelog entry (a [user-readable short description], so ci/jobs/scripts/workflow_hooks/pr_body_check.py reports Changelog entry required for category 'New Feature'.
  • Suggested replacement:
### Changelog entry (a [user-readable short description](https://github.com/ClickHouse/ClickHouse/blob/master/docs/changelog_entry_guidelines.md) of the changes that goes into CHANGELOG.md):

Add `read-checksums` command to `clickhouse-disks`. It reads the `checksums.txt` file of a `MergeTree` data part and prints it as a human-readable, tab-separated table.
Final Verdict

Status: ⚠️ Request changes

Minimum required action: restore the valid Changelog entry header so the required entry is detected by the PR body checker.

@clickhouse-gh clickhouse-gh Bot added the pr-improvement Pull request with some product improvements label Jun 9, 2026
Comment thread programs/disks/CommandReadChecksums.cpp Resolved
@asya-ch

asya-ch commented Jun 10, 2026

Copy link
Copy Markdown
Collaborator Author

The issue for this task is #105018. Others commands are in other PRs.

@murphy-4o murphy-4o self-assigned this Jun 11, 2026
Comment thread programs/disks/CommandReadChecksums.cpp Resolved
Comment thread programs/disks/CommandReadChecksums.cpp Resolved
@clickhouse-gh clickhouse-gh Bot added pr-feature Pull request with new product feature and removed pr-improvement Pull request with some product improvements labels Jun 11, 2026
Comment thread programs/disks/CommandReadChecksums.cpp Resolved
asya-ch and others added 6 commits June 16, 2026 18:46
UnityCatalog::getCredentialsConfigurationCallback was throwing BAD_ARGUMENTS when StorageID lacked a UUID. This occurred when catalog metadata had no table_id field, even though credentials weren't needed (vended_credentials=false or local storage).

Return std::nullopt instead—consistent with the base ICatalog interface, which allows missing callbacks when they cannot be provided.

Co-Authored-By: Claude Haiku 4.5 <[email protected]>
@clickhouse-gh

clickhouse-gh Bot commented Jun 17, 2026

Copy link
Copy Markdown
Contributor

📊 Cloud Performance Report

✅ AI verdict: no_change — no significant changes across 38 queries analysed

This PR only adds a new read-checksums command to the clickhouse-disks CLI utility, along with its docs and a stateless test; it does not modify any server query-execution code. Because the path these benchmark queries exercise is entirely untouched, none of the flagged deltas can be attributed to the change. All flagged improvements (clickbench Q4/Q15/Q22/Q23/Q28/Q32, tpch Q7/Q20) and the flagged regressions (clickbench Q17, tpch Q8) were therefore downgraded to run-to-run variance, consistent with the noisy/trending histories several of them carry.

clickbench

⚠️ 8 inconclusive

Flagged queries (8 of 43)
Query Verdict Baseline med (ms) PR med (ms) Change q-value Hint
⚠️ 4 not_sure 264 223 -15.5% <0.0001 PR only adds a read-checksums command to the clickhouse-disks CLI; server query path untouched, so this delta is varianc
⚠️ 15 not_sure 246 205 -16.7% <0.0001 clickhouse-disks CLI addition cannot touch this SELECT's execution path; treat -16.7% as run-to-run variance
⚠️ 17 not_sure 564 622 +10.1% <0.0001 flagged +10% regression but diff is a CLI-utility command only; not plausibly caused by this PR
⚠️ 18 not_sure 1403 1326 -5.5% 0.0011 already not_sure; diff is CLI-only, no server-path change to explain the delta
⚠️ 22 not_sure 334 237 -29.0% <0.0001 diff is CLI-only and these measurements were very noisy; -29% is not attributable to this PR
⚠️ 23 not_sure 297 206 -30.6% <0.0001 clean -31% but PR only adds a clickhouse-disks command; execution hot path untouched, so variance
⚠️ 28 not_sure 7016 6654 -5.2% 0.0010 CLI-utility addition cannot speed up this query; -5% is run-to-run variance
⚠️ 32 not_sure 1367 1282 -6.2% <0.0001 borderline -6% on a diff that only touches the clickhouse-disks CLI; unrelated to this PR

q-value = BH-FDR adjusted p; smaller is stronger evidence. MIRAI flags a query when q < fdr_q (default 0.10) — the value the verdict is based on.

tpch_adapted_1_official

⚠️ 3 inconclusive

Flagged queries (3 of 22)
Query Verdict Baseline med (ms) PR med (ms) Change q-value Hint
⚠️ 7 not_sure 113 74 -34.5% <0.0001 noisy history and a CLI-only diff; -34.5% cannot be attributed to this PR
⚠️ 8 not_sure 156 183 +17.7% <0.0001 flagged +17.7% regression but diff is a clickhouse-disks command only; server path untouched
⚠️ 20 not_sure 248 121 -51.2% <0.0001 very noisy query and a CLI-only diff; -51% is variance, not a PR effect

q-value = BH-FDR adjusted p; smaller is stronger evidence. MIRAI flags a query when q < fdr_q (default 0.10) — the value the verdict is based on.

Debug info
  • StressHouse run: d91f7415-e3bf-4659-a225-e998c99bfbe3
  • MIRAI run: 74a642c6-9329-4573-a70b-7630b9c52402
  • PR check IDs:
    • clickbench_73710_1781725178
    • clickbench_73724_1781725178
    • clickbench_73731_1781725178
    • tpch_adapted_1_official_73737_1781725178
    • tpch_adapted_1_official_73744_1781725178
    • tpch_adapted_1_official_73753_1781725178

@clickhouse-gh

clickhouse-gh Bot commented Jun 18, 2026

Copy link
Copy Markdown
Contributor

LLVM Coverage Report

Metric Baseline Current Δ
Lines 85.20% 85.30% +0.10%
Functions 92.30% 92.30% +0.00%
Branches 77.50% 77.50% +0.00%

Changed lines: Changed C/C++ lines covered by tests: 44/46 (95.65%) | Lost baseline coverage: none · Uncovered code

Full report · Diff report

@asya-ch
asya-ch added this pull request to the merge queue Jun 18, 2026
Merged via the queue into master with commit 873c0fb Jun 18, 2026
162 of 165 checks passed
@asya-ch
asya-ch deleted the asya/checksums branch June 18, 2026 18:37
@robot-ch-test-poll2 robot-ch-test-poll2 added the pr-synced-to-cloud The PR is synced to the cloud repo label Jun 18, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-feature Pull request with new product feature pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants