[
https://issues.apache.org/jira/browse/FLINK-40522?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
ASF GitHub Bot updated FLINK-40522:
-----------------------------------
Labels: pull-request-available (was: )
> Deduplicate the RecoveryCheckpointBarrier sentinel helpers shared by
> LocalInputChannel and RemoteInputChannel
> -------------------------------------------------------------------------------------------------------------
>
> Key: FLINK-40522
> URL: https://issues.apache.org/jira/browse/FLINK-40522
> Project: Flink
> Issue Type: Sub-task
> Components: Runtime / Checkpointing
> Reporter: Rui Fan
> Assignee: Rui Fan
> Priority: Major
> Labels: pull-request-available
>
> `LocalInputChannel` and `RemoteInputChannel` each define a byte-identical
> pair of stateless static helpers for the checkpointing-during-recovery
> sentinel protocol: `releaseRetainedBuffers(List<Buffer>)` and
> `asRecoveryCheckpointBarrier(Buffer)`. Keeping two copies invites silent
> drift in recovery-barrier handling.
> Fix: move the two helpers into one package-private class (e.g.
> `RecoveryCheckpointBarrierUtils`) in
> `org.apache.flink.runtime.io.network.partition.consumer` and have both
> channels delegate. This is a pure move with no behavior change.
>
> The larger `collectPreRecoveryBarrier` is intentionally left per-channel: the
> two walk different queue types (`Deque<Buffer>` vs
> `PrioritizedDeque<SequenceBuffer>`), so sharing it would add complexity
> without a clear benefit.
--
This message was sent by Atlassian Jira
(v8.20.10#820010)