DAOS-17321 ddb: Checksum management with vos API#18287
Closed
knard38 wants to merge 2 commits into
Closed
Conversation
2fd6d30 to
0c45695
Compare
|
Ticket title is 'Checksum management with ddb' |
Fix resource leak in io_sgl_fetch(): move d_sgl_fini() before the error check so the SGL is freed regardless of vos_obj_update() return code. Fix missing newline in two D_PRINT() calls in vos_tests.c. Apply clang-format alignment to VOS_OF_* enum in vos_types.h to fix pre-existing clang-format non-conformance. Reformat io_test_init_csummer() in vts_io.c to match clang-format style. Signed-off-by: Cedric Koch-Hofer <cedric.koch-hofer@hpe.com>
0c45695 to
998a14f
Compare
Add VOS_OF_FETCH_CSUM (1 << 21) flag to vos_fetch_begin() allowing callers to retrieve per-extent checksum metadata without fetching the actual data. This is intended for the ddb (DAOS Debugger) tool which needs to inspect and manage checksums stored in VOS. When VOS_OF_FETCH_CSUM is set: - SGL/bio-buffer allocation is skipped (like VOS_OF_FETCH_SIZE_ONLY). - For single-value records: save_csum() is called, then the data fetch is skipped. iod_size is not updated. - For array records: save_csum() is called as normal, and the full stored extent bounds (en_ext) plus epoch are saved via save_recx() so that callers get the raw per-version extent list paired with their checksums via vos_ioh2recx_list() and vos_ioh2ci(). VOS_OF_FETCH_CSUM and VOS_OF_FETCH_RECX_LIST are mutually exclusive since both write ic_recx_lists with incompatible semantics. An explicit -DER_INVAL check is added in vos_ioc_create() (in addition to the existing D_ASSERT in the hot path). Add unit tests for the new flag: - VOS400.1: Fetch checksum of a single-value record (CRC64). - VOS401.1: Fetch checksums of overlapping array extents (CRC16). Features: recovery Signed-off-by: Cedric Koch-Hofer <cedric.koch-hofer@hpe.com>
998a14f to
2a922ea
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
TODO
Steps for the author:
After all prior steps are complete: