Skip to content

Conversation

@suzmue
Copy link
Collaborator

@suzmue suzmue commented Aug 16, 2025

Remove the generic parameters for checksums from the public API. This does open the API to misuse a little easier, since we no longer can limit which setters for the checksum are enabled based on the type.

To simplify, remove the ChecksumEngine trait all together and create a new struct that holds a Crc32c and Md5 and let WriteObject and ReadObject do simple manipulations on them.

For #2896 , #2895

@codecov
Copy link

codecov bot commented Aug 16, 2025

Codecov Report

❌ Patch coverage is 97.95918% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 96.70%. Comparing base (c9607c5) to head (0390253).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/storage/src/storage/write_object.rs 96.42% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2907      +/-   ##
==========================================
+ Coverage   96.19%   96.70%   +0.50%     
==========================================
  Files         105      105              
  Lines        4411     4365      -46     
==========================================
- Hits         4243     4221      -22     
+ Misses        168      144      -24     

☔ View full report in Codecov by Sentry.
📢 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.

Copy link
Collaborator

@coryan coryan left a comment

Choose a reason for hiding this comment

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

This will probably conflict with #2906 , but the fixes will be (I hope) easy

Copy link
Member

@dbolduc dbolduc left a comment

Choose a reason for hiding this comment

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

This is awesome! Thanks!

I just have an optional nit that could save some lines of code.

@suzmue suzmue marked this pull request as ready for review August 21, 2025 22:30
@suzmue suzmue requested a review from a team as a code owner August 21, 2025 22:30
@suzmue
Copy link
Collaborator Author

suzmue commented Aug 21, 2025

@dbolduc I'll submit as is to make your work easier, and implement the nits in a follow up.

@suzmue suzmue merged commit 6a5c800 into googleapis:main Aug 21, 2025
23 checks passed
@suzmue suzmue deleted the checksum_to_enum branch August 21, 2025 22:32
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.

3 participants