Skip to content

refactor(cpp): remove unused TsBlock helpers - #1137

Open
ColinLeeo wants to merge 1 commit into
developfrom
colin/cpp-tsblock-deadcode
Open

ColinLeeo wants to merge 1 commit into
developfrom
colin/cpp-tsblock-deadcode

Conversation

@ColinLeeo

Copy link
Copy Markdown
Contributor

Summary

  • Remove TsBlock::tsblock_to_json() and its private write_data() helper: no callers in the repo, and the JSON dump was only reachable from itself.
  • Remove merge_tsblock_by_row(): no callers; row-by-row merging was never wired into any read path.
  • Remove unused TsBlock::get_capacity() / update_capacity().
  • Drop the unused select_list_ member and its stale "not initialized" comment.
  • Drop the now-unused common/allocator/byte_stream.h include from tsblock.h.

These were the main reason tsblock.cc sat at 17% line coverage: the dead functions accounted for roughly 150 of its uncovered lines.

Test plan

  • ./mvnw verify -P with-cpp — 1875 tests passed
  • ./mvnw clean verify -P with-cpp -Denable.asan=ON -Dbuild.type=RelWithDebInfo -Denable.lzma2=ON — 1878 tests passed
  • ./mvnw spotless:check -P with-cpp
  • Repo-wide grep confirms no remaining references to the removed symbols

@codecov-commenter

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 68.83%. Comparing base (0d89263) to head (260849d).
⚠️ Report is 1 commits behind head on develop.

Additional details and impacted files
@@             Coverage Diff             @@
##           develop    #1137      +/-   ##
===========================================
+ Coverage    68.79%   68.83%   +0.04%     
===========================================
  Files          790      790              
  Lines        58317    58276      -41     
  Branches      9450     9432      -18     
===========================================
  Hits         40117    40117              
+ Misses       16487    16445      -42     
- Partials      1713     1714       +1     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants