jojochuang commented on PR #11068: URL: https://github.com/apache/ozone/pull/11068#issuecomment-5431117970
@SaketaChalamchala — I took a pass at refactoring `TypedTable.multiGetFromTable()` to address the duplicated status handling between the first pass and the oversize retry loop. **Branch:** https://github.com/jojochuang/ozone/tree/HDDS-16229-refactor **Commit:** https://github.com/jojochuang/ozone/commit/0504b5bc8e4 ### What changed - Split the CodecBuffer vs byte[] paths into `multiGetFromTableWithCodecBuffer()` / `multiGetFromTableWithByteArray()`. - Extracted shared helpers: - `applyMultiGetStatuses()` — first pass (decode or queue retry when `requiredSize > capacity`) - `retryOversizedMultiGet()` — second batch for oversize keys - `validateMultiGetStatus()`, `decodeFromMultiGetStatus()`, `addWritableValueByteBuffer()` - Retry keys use `keyByteBuffer.duplicate()` so we don't reuse a buffer whose position may have moved. Behavior should be unchanged; this is a readability/dedup refactor only. ### Validation - `TestRDBTable` - `TestRDBTableStore#multiGetSkipCache` - `TestRDBTableStore#multiGetSkipCacheWithTypedTable` - checkstyle on `:hdds-server-framework` Feel free to cherry-pick or adapt if useful. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
