Class DataGenTableSource

java.lang.Object
org.apache.flink.connector.datagen.table.DataGenTableSource
All Implemented Interfaces:
org.apache.flink.table.connector.source.abilities.SupportsLimitPushDown, org.apache.flink.table.connector.source.DynamicTableSource, org.apache.flink.table.connector.source.ScanTableSource

@Internal public class DataGenTableSource extends Object implements org.apache.flink.table.connector.source.ScanTableSource, org.apache.flink.table.connector.source.abilities.SupportsLimitPushDown
A StreamTableSource that emits generated data rows.
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.apache.flink.table.connector.source.DynamicTableSource

    org.apache.flink.table.connector.source.DynamicTableSource.Context, org.apache.flink.table.connector.source.DynamicTableSource.DataStructureConverter

    Nested classes/interfaces inherited from interface org.apache.flink.table.connector.source.ScanTableSource

    org.apache.flink.table.connector.source.ScanTableSource.ScanContext, org.apache.flink.table.connector.source.ScanTableSource.ScanRuntimeProvider
  • Constructor Summary

    Constructors
    Constructor
    Description
    DataGenTableSource(org.apache.flink.streaming.api.functions.source.datagen.DataGenerator<?>[] fieldGenerators, String tableName, org.apache.flink.table.types.DataType rowDataType, long rowsPerSecond, Long numberOfRows, Integer parallelism)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    applyLimit(long limit)
     
     
    org.apache.flink.table.connector.source.DynamicTableSource
     
    org.apache.flink.streaming.api.functions.source.datagen.DataGeneratorSource<org.apache.flink.table.data.RowData>
     
    org.apache.flink.table.connector.ChangelogMode
     
    org.apache.flink.table.connector.source.ScanTableSource.ScanRuntimeProvider
    getScanRuntimeProvider(org.apache.flink.table.connector.source.ScanTableSource.ScanContext context)
     

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

    • DataGenTableSource

      public DataGenTableSource(org.apache.flink.streaming.api.functions.source.datagen.DataGenerator<?>[] fieldGenerators, String tableName, org.apache.flink.table.types.DataType rowDataType, long rowsPerSecond, Long numberOfRows, Integer parallelism)
  • Method Details

    • getScanRuntimeProvider

      public org.apache.flink.table.connector.source.ScanTableSource.ScanRuntimeProvider getScanRuntimeProvider(org.apache.flink.table.connector.source.ScanTableSource.ScanContext context)
      Specified by:
      getScanRuntimeProvider in interface org.apache.flink.table.connector.source.ScanTableSource
    • createSource

      @VisibleForTesting public org.apache.flink.streaming.api.functions.source.datagen.DataGeneratorSource<org.apache.flink.table.data.RowData> createSource()
    • copy

      public org.apache.flink.table.connector.source.DynamicTableSource copy()
      Specified by:
      copy in interface org.apache.flink.table.connector.source.DynamicTableSource
    • asSummaryString

      public String asSummaryString()
      Specified by:
      asSummaryString in interface org.apache.flink.table.connector.source.DynamicTableSource
    • getChangelogMode

      public org.apache.flink.table.connector.ChangelogMode getChangelogMode()
      Specified by:
      getChangelogMode in interface org.apache.flink.table.connector.source.ScanTableSource
    • applyLimit

      public void applyLimit(long limit)
      Specified by:
      applyLimit in interface org.apache.flink.table.connector.source.abilities.SupportsLimitPushDown