@Internal public class CheckpointedInputGate extends Object implements org.apache.flink.runtime.io.PullingAsyncDataInput<org.apache.flink.runtime.io.network.partition.consumer.BufferOrEvent>, Closeable
CheckpointedInputGate uses CheckpointBarrierHandler to handle incoming CheckpointBarrier from the InputGate.| Constructor and Description |
|---|
CheckpointedInputGate(org.apache.flink.runtime.io.network.partition.consumer.InputGate inputGate,
CheckpointBarrierHandler barrierHandler,
MailboxExecutor mailboxExecutor)
Creates a new checkpoint stream aligner.
|
CheckpointedInputGate(org.apache.flink.runtime.io.network.partition.consumer.InputGate inputGate,
CheckpointBarrierHandler barrierHandler,
MailboxExecutor mailboxExecutor,
UpstreamRecoveryTracker upstreamRecoveryTracker) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
allChannelsRecovered() |
void |
close()
Cleans up all internally held resources.
|
CompletableFuture<Void> |
getAllBarriersReceivedFuture(long checkpointId) |
CompletableFuture<?> |
getAvailableFuture() |
org.apache.flink.runtime.io.network.partition.consumer.InputChannel |
getChannel(int channelIndex) |
List<org.apache.flink.runtime.checkpoint.channel.InputChannelInfo> |
getChannelInfos() |
int |
getNumberOfInputChannels() |
boolean |
isFinished() |
Optional<org.apache.flink.runtime.io.network.partition.consumer.BufferOrEvent> |
pollNext() |
String |
toString() |
public CheckpointedInputGate(org.apache.flink.runtime.io.network.partition.consumer.InputGate inputGate,
CheckpointBarrierHandler barrierHandler,
MailboxExecutor mailboxExecutor)
The aligner will allow only alignments that buffer up to the given number of bytes. When that number is exceeded, it will stop the alignment and notify the task that the checkpoint has been cancelled.
inputGate - The input gate to draw the buffers and events from.barrierHandler - Handler that controls which channels are blocked.public CheckpointedInputGate(org.apache.flink.runtime.io.network.partition.consumer.InputGate inputGate,
CheckpointBarrierHandler barrierHandler,
MailboxExecutor mailboxExecutor,
UpstreamRecoveryTracker upstreamRecoveryTracker)
public CompletableFuture<?> getAvailableFuture()
getAvailableFuture in interface org.apache.flink.runtime.io.AvailabilityProviderpublic Optional<org.apache.flink.runtime.io.network.partition.consumer.BufferOrEvent> pollNext() throws IOException, InterruptedException
pollNext in interface org.apache.flink.runtime.io.PullingAsyncDataInput<org.apache.flink.runtime.io.network.partition.consumer.BufferOrEvent>IOExceptionInterruptedExceptionpublic CompletableFuture<Void> getAllBarriersReceivedFuture(long checkpointId)
public boolean isFinished()
isFinished in interface org.apache.flink.runtime.io.PullingAsyncDataInput<org.apache.flink.runtime.io.network.partition.consumer.BufferOrEvent>public void close()
throws IOException
close in interface Closeableclose in interface AutoCloseableIOException - Thrown if the cleanup of I/O resources failed.public int getNumberOfInputChannels()
public org.apache.flink.runtime.io.network.partition.consumer.InputChannel getChannel(int channelIndex)
public List<org.apache.flink.runtime.checkpoint.channel.InputChannelInfo> getChannelInfos()
public boolean allChannelsRecovered()
Copyright © 2014–2022 The Apache Software Foundation. All rights reserved.