[ 
https://issues.apache.org/jira/browse/HDDS-17792?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

ASF GitHub Bot updated HDDS-17792:
----------------------------------
    Labels: pull-request-available  (was: )

> Incorrect replicated and unreplicated size calculation for deleted keys 
> during reprocessing
> -------------------------------------------------------------------------------------------
>
>                 Key: HDDS-17792
>                 URL: https://issues.apache.org/jira/browse/HDDS-17792
>             Project: Apache Ozone
>          Issue Type: Bug
>          Components: Ozone Recon
>            Reporter: Navin Kumar
>            Assignee: Navin Kumar
>            Priority: Major
>              Labels: pull-request-available
>         Attachments: Screenshot 2026-11-12 at 12.30.29 AM.png
>
>
> While replacing ImmutablePair in RepeatedOmKeyInfo.getTotalSize() for 
> HDDS-17753
> I reviewed its callers and found that 
> DeletedKeysInsightHandler.getTableSizeAndCount() assigns getRight() 
> (replicated size) to the unreplicated total and getLeft() (unreplicated size) 
> to the replicated total. 
> This is the reverse of how handlePutEvent and handleDeleteEvent in the same 
> class processed the two metrics, so every full reprocess in Recon reports 
> swapped sizes for the deleted table.
> Validated the same with existing test case: 
> TestOmTableInsightTask#testReprocessForCount by providing different values 
> for Unreplicated and replicate size and found test case fails.
> {noformat}
> / Five deleted entries, each with 100 bytes unreplicated and 300 bytes
> // replicated, should produce totals of 500 and 1500 bytes respectively.
> // These assertions detect a typo ie: reversal of the two size metrics.
> assertEquals(500L, getUnReplicatedSizeForTable(DELETED_TABLE));
> assertEquals(1500L, getReplicatedSizeForTable(DELETED_TABLE));{noformat}
> The expectation for HDDS-17753 is no behaviour change hence call out (filed 
> the bug) and fix the found bug .



--
This message was sent by Atlassian Jira
(v10.3.26#10030026)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to