public class CompactionCommitSink extends CleanFunction<CompactionCommitEvent>
Each time after receiving a compaction commit event CompactionCommitEvent,
it loads and checks the compaction plan HoodieCompactionPlan,
if all the compaction operations CompactionOperation
of the plan are finished, tries to commit the compaction action.
It also inherits the CleanFunction cleaning ability. This is needed because
the SQL API does not allow multiple sinks in one table sink provider.
writeClient| Constructor and Description |
|---|
CompactionCommitSink(org.apache.flink.configuration.Configuration conf) |
| Modifier and Type | Method and Description |
|---|---|
void |
invoke(CompactionCommitEvent event,
org.apache.flink.streaming.api.functions.sink.SinkFunction.Context context) |
void |
open(org.apache.flink.configuration.Configuration parameters) |
close, initializeState, notifyCheckpointComplete, snapshotStategetIterationRuntimeContext, getRuntimeContext, setRuntimeContextclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitpublic CompactionCommitSink(org.apache.flink.configuration.Configuration conf)
public void open(org.apache.flink.configuration.Configuration parameters)
throws Exception
open in interface org.apache.flink.api.common.functions.RichFunctionopen in class CleanFunction<CompactionCommitEvent>Exceptionpublic void invoke(CompactionCommitEvent event, org.apache.flink.streaming.api.functions.sink.SinkFunction.Context context) throws Exception
ExceptionCopyright © 2022 The Apache Software Foundation. All rights reserved.