chihsuan opened a new pull request, #11235: URL: https://github.com/apache/ozone/pull/11235
## What changes were proposed? Follow-up to #10633. For write requests that ask for sorted datanodes with `ozone.om.block.write.sort.datanodes.enabled=true` (disabled by default): - Look up the client's rack once per allocation request. - Let SCM sort if OM cannot find the client's rack. - Return `null` when OM skips sorting because a pipeline datanode is missing from its topology, preserving the pipeline's order. - Continue putting a datanode matching the client's address first when OM sorts. The lookup happens before calling SCM to avoid repeated lookups and allow SCM fallback. Using `null` makes skipped sorting explicit. `AllocateBlockSortDatanodesLatencyNs` now records lookup and sorting as separate samples. ## JIRA https://issues.apache.org/jira/browse/HDDS-15941 ## Testing - `TestOMAllocateBlockRequest` and related key/file-create suites: 235 tests passed. - `TestOMSortDatanodes`: 9 tests passed, covering client lookup, nearest-first sorting, and missing topology entries. - Checkstyle: zero violations. These results are from earlier local runs with JDK 17. Validation with JDK 21 is still needed. Generated-by: Claude Code (Claude Opus 5) 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01Gf5BdnivX8uwyr3wnwPfjC -- 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]
