public class StreamingFileCommitter extends org.apache.flink.streaming.api.operators.AbstractStreamOperator<Void> implements org.apache.flink.streaming.api.operators.OneInputStreamOperator<StreamingFileCommitter.CommitMessage,Void>
StreamingFileWriter. This is the single (non-parallel) task.
It collects all the partition information sent from upstream, and triggers the partition
submission decision when it judges to collect the partitions from all tasks of a checkpoint.
Processing steps:
1.Partitions are sent from upstream. Add partition to trigger.
2.TaskTracker say it have already received partition data from all tasks in a checkpoint.
3.Extracting committable partitions from PartitionCommitTrigger.
4.Using PartitionCommitPolicy chain to commit partitions.
| 限定符和类型 | 类和说明 |
|---|---|
static class |
StreamingFileCommitter.CommitMessage
The message sent upstream.
|
| 构造器和说明 |
|---|
StreamingFileCommitter(org.apache.flink.core.fs.Path locationPath,
org.apache.flink.table.catalog.ObjectIdentifier tableIdentifier,
List<String> partitionKeys,
TableMetaStoreFactory metaStoreFactory,
FileSystemFactory fsFactory,
org.apache.flink.configuration.Configuration conf) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
initializeState(org.apache.flink.runtime.state.StateInitializationContext context) |
void |
processElement(org.apache.flink.streaming.runtime.streamrecord.StreamRecord<StreamingFileCommitter.CommitMessage> element) |
void |
processWatermark(org.apache.flink.streaming.api.watermark.Watermark mark) |
void |
snapshotState(org.apache.flink.runtime.state.StateSnapshotContext context) |
close, dispose, getChainingStrategy, getContainingTask, getCurrentKey, getExecutionConfig, getInternalTimerService, getKeyedStateBackend, getKeyedStateStore, getMetricGroup, getOperatorConfig, getOperatorID, getOperatorName, getOperatorStateBackend, getOrCreateKeyedState, getPartitionedState, getPartitionedState, getProcessingTimeService, getRuntimeContext, getTimeServiceManager, getUserCodeClassloader, initializeState, notifyCheckpointAborted, notifyCheckpointComplete, numEventTimeTimers, numProcessingTimeTimers, open, prepareSnapshotPreBarrier, processLatencyMarker, processLatencyMarker1, processLatencyMarker2, processWatermark1, processWatermark2, reportOrForwardLatencyMarker, setChainingStrategy, setCurrentKey, setKeyContextElement1, setKeyContextElement2, setProcessingTimeService, setup, snapshotStateclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitclose, dispose, getMetricGroup, getOperatorID, initializeState, open, prepareSnapshotPreBarrier, setKeyContextElement1, setKeyContextElement2, snapshotStatepublic StreamingFileCommitter(org.apache.flink.core.fs.Path locationPath,
org.apache.flink.table.catalog.ObjectIdentifier tableIdentifier,
List<String> partitionKeys,
TableMetaStoreFactory metaStoreFactory,
FileSystemFactory fsFactory,
org.apache.flink.configuration.Configuration conf)
public void initializeState(org.apache.flink.runtime.state.StateInitializationContext context)
throws Exception
public void processElement(org.apache.flink.streaming.runtime.streamrecord.StreamRecord<StreamingFileCommitter.CommitMessage> element) throws Exception
processElement 在接口中 org.apache.flink.streaming.api.operators.OneInputStreamOperator<StreamingFileCommitter.CommitMessage,Void>Exceptionpublic void processWatermark(org.apache.flink.streaming.api.watermark.Watermark mark)
throws Exception
processWatermark 在接口中 org.apache.flink.streaming.api.operators.OneInputStreamOperator<StreamingFileCommitter.CommitMessage,Void>processWatermark 在类中 org.apache.flink.streaming.api.operators.AbstractStreamOperator<Void>Exceptionpublic void snapshotState(org.apache.flink.runtime.state.StateSnapshotContext context)
throws Exception
Copyright © 2014–2020 The Apache Software Foundation. All rights reserved.