Class KafkaDataSourcesProvider

  • All Implemented Interfaces:
    DataSourcesProvider

    public class KafkaDataSourcesProvider
    extends Object
    implements DataSourcesProvider
    Create a Kafka spout/sink based on the URI and properties. The URI has the format of kafka://topic?bootstrap-servers=ip:port[,ip:port]. The properties are in JSON format which specifies the producer config of the Kafka broker.
    • Constructor Detail

      • KafkaDataSourcesProvider

        public KafkaDataSourcesProvider()
    • Method Detail

      • constructStreams

        public ISqlStreamsDataSource constructStreams​(URI uri,
                                                      String inputFormatClass,
                                                      String outputFormatClass,
                                                      Properties properties,
                                                      List<FieldInfo> fields)
        Description copied from interface: DataSourcesProvider
        Construct a new data source for streams mode.
        Specified by:
        constructStreams in interface DataSourcesProvider
        Parameters:
        uri - The URI that specifies the data source. The format of the URI is fully customizable.
        inputFormatClass - the name of the class that deserializes data. It is null when unspecified.
        outputFormatClass - the name of the class that serializes data. It is null when unspecified.
        fields - The name of the fields and the schema of the table.