dombizita opened a new pull request, #10991: URL: https://github.com/apache/ozone/pull/10991
## What changes were proposed in this pull request? This PR wires the write pipeline version (the component version SCM advertises for a pipeline) from the client through to the datanode that executes the write, so that all datanodes in a pipeline perform a given write at the same version during a rolling upgrade. During a ZDU, datanodes finalize at different times, so a pipeline can temporarily mix finalized and unfinalized datanodes. Coupling versions to pipelines/subgroups is unmanageable at scale, and the old framework's approach of closing all pipelines and containers on finalization does not work for ZDU. Datanodes also cannot learn the version from each other, since peers do not communicate on the erasure coding write path. The [design](https://github.com/apache/ozone/pull/9664/changes) (see "Mixed Datanode Versions During Write") therefore has the client carry the version to the datanodes. SCM already computes the version (the minimum apparent version across all datanodes in the pipeline, pinned to `STREAM_BLOCK_SUPPORT` pre-ZDU) and stamps it onto DatanodeDetails.currentVersion in the block-allocation response (#10878). This PR does the remaining two hops: - A new optional field `writePipelineVersion` is added to `ContainerCommandRequestProto`. On write requests the client copies the SCM-provided pipeline version straight onto the request. - `ContainerStateMachine` reads the field via a new `ClientCommandsUtils.getWritePipelineVersion(request)` helper and stores it on `DispatcherContext` at all three write entry points: `writeStateMachineData`, `stream`, and `applyTransaction`. This makes the negotiated version available to the whole write path so future features can rely on it. Future write-path changes can gate behavior on `dispatcherContext.getWriteVersion()`. ## What is the link to the Apache JIRA https://issues.apache.org/jira/browse/HDDS-15718 ## How was this patch tested? Green CI: https://github.com/dombizita/ozone/actions/runs/30738966374 -- 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]
