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

Rui Fan updated FLINK-39524:
----------------------------
    Description: 
Introduce the on-disk subsystem for recovered channel state. Runtime behavior 
is unchanged: the handler factory does not select the new handlers, so no 
production path produces or consumes spill files.

Scope:
 * FetchedChannelState: ref-counted container over an ordered list of spill 
files (files deleted when the last grant is released) with a one-shot 
snapshot/resume point (FetchedChannelStateSnapshot).
 * Spill-writing handlers: AbstractSpillingHandler owns the append-only 
segmented on-disk format ([gateIdx][channelIdx][bufferLength][body], length 
backfill, 64 MiB rotation, OffsetAwareOutputStream); SpillingNoFilteringHandler 
writes recovered buffers verbatim.
 * ChannelStateFilteringHandler rewritten to emit surviving records 
length-prefixed into a spill segment (previously it produced network buffers 
delivered to the channels); SpillingWithFilteringHandler routes rescale-filter 
output to disk.
 * FetchedChannelStateReader / FetchedChannelStateReaderImpl: forward-only 
segment reader with committed/current positions and snapshot resume.
 * SequentialChannelStateReader#readInputData returns Optional (empty as long 
as no handler produces spilled state).

  was:`ChannelStateFilteringHandler.filterAndRewrite()` now pushes filtered 
bytes directly to `OutputWriter.write()` instead of returning a `List<Buffer>`. 
`RecoveredChannelStateHandler.recoverWithFiltering()` drops the buffer-return 
handling, and `SequentialChannelStateReaderImpl` creates one per-task 
OutputWriter plus per-channel RecoveredBufferStores and orchestrates the 
shutdown sequence `flush → finishReadRecoveredState → close(blocking drain)`.


> Introduce the fetched-channel-state spill subsystem (segmented spill files, 
> filtered write, reader)
> ---------------------------------------------------------------------------------------------------
>
>                 Key: FLINK-39524
>                 URL: https://issues.apache.org/jira/browse/FLINK-39524
>             Project: Flink
>          Issue Type: Sub-task
>            Reporter: Rui Fan
>            Assignee: Rui Fan
>            Priority: Major
>
> Introduce the on-disk subsystem for recovered channel state. Runtime behavior 
> is unchanged: the handler factory does not select the new handlers, so no 
> production path produces or consumes spill files.
> Scope:
>  * FetchedChannelState: ref-counted container over an ordered list of spill 
> files (files deleted when the last grant is released) with a one-shot 
> snapshot/resume point (FetchedChannelStateSnapshot).
>  * Spill-writing handlers: AbstractSpillingHandler owns the append-only 
> segmented on-disk format ([gateIdx][channelIdx][bufferLength][body], length 
> backfill, 64 MiB rotation, OffsetAwareOutputStream); 
> SpillingNoFilteringHandler writes recovered buffers verbatim.
>  * ChannelStateFilteringHandler rewritten to emit surviving records 
> length-prefixed into a spill segment (previously it produced network buffers 
> delivered to the channels); SpillingWithFilteringHandler routes 
> rescale-filter output to disk.
>  * FetchedChannelStateReader / FetchedChannelStateReaderImpl: forward-only 
> segment reader with committed/current positions and snapshot resume.
>  * SequentialChannelStateReader#readInputData returns Optional (empty as long 
> as no handler produces spilled state).



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to