Skip to content

Conversation

@sanebay
Copy link
Contributor

@sanebay sanebay commented Feb 10, 2026

Check is blk alloced for normal volume write free blk.

In crash recovery case, volume write can write to index
and to disk and then crash. In this case index has stale
blk ids which are not alloced, but they can be freed next
time a write happens on same lba.
Ex: write on lba=100 with blk1, add blk1 in index. crash and restart(no journal write)
write again on lba=100 with blk2, get blk1 from index to free the old blks(this is not allocated at all because it was not commited)

In crash recovery case, volume write can write to index
and to disk and then crash. In this case index has stale
blk ids which are not alloced, but they can be freed next
time a write happens on same lba.
@sanebay sanebay changed the title Blk free fix Check is blk alloced for normal volume write free blk. Feb 10, 2026
@codecov-commenter
Copy link

⚠️ Please install the 'codecov app svg image' to ensure uploads and comments are reliably processed by Codecov.

Codecov Report

❌ Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 46.80%. Comparing base (0b40663) to head (5259529).
⚠️ Report is 64 commits behind head on main.

Files with missing lines Patch % Lines
src/lib/volume/volume.cpp 0.00% 0 Missing and 2 partials ⚠️
src/lib/volume_mgr.cpp 0.00% 0 Missing and 2 partials ⚠️
❗ Your organization needs to install the Codecov GitHub app to enable full functionality.
Additional details and impacted files
@@             Coverage Diff             @@
##             main     #158       +/-   ##
===========================================
- Coverage   61.68%   46.80%   -14.89%     
===========================================
  Files          15       16        +1     
  Lines         462     1126      +664     
  Branches       35      541      +506     
===========================================
+ Hits          285      527      +242     
- Misses        158      227       +69     
- Partials       19      372      +353     

☔ 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
Contributor

@shosseinimotlagh shosseinimotlagh left a comment

Choose a reason for hiding this comment

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

LG!

@sanebay sanebay merged commit 41603ac into eBay:main Feb 11, 2026
35 of 38 checks passed
@sanebay sanebay deleted the blk_free_fix branch February 11, 2026 20:00
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