You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@ozone.apache.org by "Tsz-wo Sze (Jira)" <ji...@apache.org> on 2026/09/15 05:06:00 UTC
[jira] [Resolved] (HDDS-15857) Fix checksum calculation in KeyValueHandler for variable-sized chunks
[ https://issues.apache.org/jira/browse/HDDS-15857?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tsz-wo Sze resolved HDDS-15857.
-------------------------------
Fix Version/s: 2.3.0
Resolution: Fixed
The pull request is now merged. Thanks, [~chungen]!
> Fix checksum calculation in KeyValueHandler for variable-sized chunks
> ---------------------------------------------------------------------
>
> Key: HDDS-15857
> URL: https://issues.apache.org/jira/browse/HDDS-15857
> Project: Apache Ozone
> Issue Type: Sub-task
> Reporter: Chung-En Lee
> Assignee: Chung-En Lee
> Priority: Major
> Labels: pull-request-available
> Fix For: 2.3.0
>
> Attachments: 10764_review.patch, 10764_review2.patch, 10764_review3b.patch
>
>
> Currently, the `getChecksums` method in `KeyValueHandler.java` fails or returns incorrect checksums when chunks have variable sizes or are smaller than bytesPerChunk.
> The original code assumes all chunks (except the last one) have a fixed size equal to `bytesPerChunk`. This assumption is incorrect when chunks have different lengths, leading to wrong index calculations.
> Crucially, when checksum verification is enabled, the DataNode must return the actual ChunkInfo (which contains chunk lengths) to the client. Without this metadata, the client cannot perceive the boundaries of each varying chunk, making it impossible to correctly map the offsets and compute/verify the checksums.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)
---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscribe@ozone.apache.org
For additional commands, e-mail: issues-help@ozone.apache.org