Class CommonExecSink
- java.lang.Object
-
- org.apache.flink.table.planner.plan.nodes.exec.ExecNodeBase<Object>
-
- org.apache.flink.table.planner.plan.nodes.exec.common.CommonExecSink
-
- All Implemented Interfaces:
ExecNode<Object>
,ExecNodeTranslator<Object>
,FusionCodegenExecNode
,MultipleTransformationTranslator<Object>
- Direct Known Subclasses:
BatchExecSink
,StreamExecSink
public abstract class CommonExecSink extends ExecNodeBase<Object> implements MultipleTransformationTranslator<Object>
BaseExecNode
to write data to an external sink defined by aDynamicTableSink
.
-
-
Field Summary
Fields Modifier and Type Field Description static String
CONSTRAINT_VALIDATOR_TRANSFORMATION
static String
FIELD_NAME_DYNAMIC_TABLE_SINK
static String
PARTITIONER_TRANSFORMATION
static String
ROW_KIND_SETTER
static String
SINK_TRANSFORMATION
protected boolean
sinkParallelismConfigured
protected DynamicTableSinkSpec
tableSinkSpec
static String
TIMESTAMP_INSERTER_TRANSFORMATION
static String
UPSERT_MATERIALIZE_TRANSFORMATION
-
Fields inherited from interface org.apache.flink.table.planner.plan.nodes.exec.ExecNode
FIELD_NAME_CONFIGURATION, FIELD_NAME_DESCRIPTION, FIELD_NAME_ID, FIELD_NAME_INPUT_PROPERTIES, FIELD_NAME_OUTPUT_TYPE, FIELD_NAME_STATE, FIELD_NAME_TYPE
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
CommonExecSink(int id, ExecNodeContext context, ReadableConfig persistedConfig, DynamicTableSinkSpec tableSinkSpec, ChangelogMode inputChangelogMode, boolean isBounded, List<InputProperty> inputProperties, LogicalType outputType, String description)
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected abstract Transformation<RowData>
applyUpsertMaterialize(Transformation<RowData> inputTransform, int[] primaryKeys, int sinkParallelism, ExecNodeConfig config, ClassLoader classLoader, RowType physicalRowType, int[] inputUpsertKey)
protected Transformation<Object>
createSinkTransformation(StreamExecutionEnvironment streamExecEnv, ExecNodeConfig config, ClassLoader classLoader, Transformation<RowData> inputTransform, DynamicTableSink tableSink, int rowtimeFieldIndex, boolean upsertMaterialize, int[] inputUpsertKey)
protected RowType
getPhysicalRowType(ResolvedSchema schema)
protected int[]
getPrimaryKeyIndices(RowType sinkRowType, ResolvedSchema schema)
String
getSimplifiedName()
DynamicTableSinkSpec
getTableSinkSpec()
-
Methods inherited from class org.apache.flink.table.planner.plan.nodes.exec.ExecNodeBase
accept, createFormattedTransformationDescription, createFormattedTransformationName, createTransformationDescription, createTransformationMeta, createTransformationMeta, createTransformationName, createTransformationUid, getContextFromAnnotation, getDescription, getId, getInputEdges, getInputProperties, getOutputType, getPersistedConfig, getTransformation, inputsContainSingleton, replaceInputEdge, setCompiled, setInputEdges, supportFusionCodegen, translateToFusionCodegenSpec, translateToFusionCodegenSpecInternal, translateToPlan, translateToPlanInternal
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.flink.table.planner.plan.nodes.exec.ExecNodeTranslator
translateToPlan
-
-
-
-
Field Detail
-
CONSTRAINT_VALIDATOR_TRANSFORMATION
public static final String CONSTRAINT_VALIDATOR_TRANSFORMATION
- See Also:
- Constant Field Values
-
PARTITIONER_TRANSFORMATION
public static final String PARTITIONER_TRANSFORMATION
- See Also:
- Constant Field Values
-
UPSERT_MATERIALIZE_TRANSFORMATION
public static final String UPSERT_MATERIALIZE_TRANSFORMATION
- See Also:
- Constant Field Values
-
TIMESTAMP_INSERTER_TRANSFORMATION
public static final String TIMESTAMP_INSERTER_TRANSFORMATION
- See Also:
- Constant Field Values
-
ROW_KIND_SETTER
public static final String ROW_KIND_SETTER
- See Also:
- Constant Field Values
-
SINK_TRANSFORMATION
public static final String SINK_TRANSFORMATION
- See Also:
- Constant Field Values
-
FIELD_NAME_DYNAMIC_TABLE_SINK
public static final String FIELD_NAME_DYNAMIC_TABLE_SINK
- See Also:
- Constant Field Values
-
tableSinkSpec
protected final DynamicTableSinkSpec tableSinkSpec
-
sinkParallelismConfigured
protected boolean sinkParallelismConfigured
-
-
Constructor Detail
-
CommonExecSink
protected CommonExecSink(int id, ExecNodeContext context, ReadableConfig persistedConfig, DynamicTableSinkSpec tableSinkSpec, ChangelogMode inputChangelogMode, boolean isBounded, List<InputProperty> inputProperties, LogicalType outputType, String description)
-
-
Method Detail
-
getSimplifiedName
public String getSimplifiedName()
- Overrides:
getSimplifiedName
in classExecNodeBase<Object>
-
getTableSinkSpec
public DynamicTableSinkSpec getTableSinkSpec()
-
createSinkTransformation
protected Transformation<Object> createSinkTransformation(StreamExecutionEnvironment streamExecEnv, ExecNodeConfig config, ClassLoader classLoader, Transformation<RowData> inputTransform, DynamicTableSink tableSink, int rowtimeFieldIndex, boolean upsertMaterialize, int[] inputUpsertKey)
-
applyUpsertMaterialize
protected abstract Transformation<RowData> applyUpsertMaterialize(Transformation<RowData> inputTransform, int[] primaryKeys, int sinkParallelism, ExecNodeConfig config, ClassLoader classLoader, RowType physicalRowType, int[] inputUpsertKey)
-
getPrimaryKeyIndices
protected int[] getPrimaryKeyIndices(RowType sinkRowType, ResolvedSchema schema)
-
getPhysicalRowType
protected RowType getPhysicalRowType(ResolvedSchema schema)
-
-