Class ColumnStatsWatermarkExtractor
java.lang.Object
org.apache.iceberg.flink.source.reader.ColumnStatsWatermarkExtractor
- All Implemented Interfaces:
- Serializable,- SplitWatermarkExtractor
@Internal
public class ColumnStatsWatermarkExtractor
extends Object
implements SplitWatermarkExtractor, Serializable
SplitWatermarkExtractor implementation which uses an Iceberg timestamp column statistics
 to get the watermarks for the IcebergSourceSplit. This watermark is emitted by the WatermarkExtractorRecordEmitter along with the actual records.- See Also:
- 
Constructor SummaryConstructorsConstructorDescriptionColumnStatsWatermarkExtractor(Schema schema, String eventTimeFieldName, TimeUnit timeUnit) Creates the extractor.
- 
Method SummaryModifier and TypeMethodDescriptionlongGet the watermark for a split using column statistics.
- 
Constructor Details- 
ColumnStatsWatermarkExtractorCreates the extractor.- Parameters:
- schema- The schema of the Table
- eventTimeFieldName- The column which should be used as an event time
- timeUnit- Used for converting the long value to epoch milliseconds
 
 
- 
- 
Method Details- 
extractWatermarkGet the watermark for a split using column statistics.- Specified by:
- extractWatermarkin interface- SplitWatermarkExtractor
- Parameters:
- split- The split
- Returns:
- The watermark
- Throws:
- IllegalArgumentException- if there is no statistics for the column
 
 
-