Class RecordsProducer

java.lang.Object
io.debezium.connector.postgresql.RecordsProducer

public abstract class RecordsProducer extends Object
Class which generates Kafka Connect SourceRecord records.
Author:
Horia Chiorean (hchiorea@redhat.com)
  • Field Details

    • logger

      protected final org.slf4j.Logger logger
    • taskContext

      protected final PostgresTaskContext taskContext
    • sourceInfo

      protected final SourceInfo sourceInfo
  • Constructor Details

  • Method Details

    • start

      protected abstract void start(BlockingConsumer<ChangeEvent> recordsConsumer, Consumer<Throwable> failureConsumer)
      Starts up this producer. This is normally done by a PostgresConnectorTask instance. Subclasses should start enqueuing records via a separate thread at the end of this method.
      Parameters:
      recordsConsumer - a consumer of ChangeEvent instances, may not be null
    • commit

      protected abstract void commit(long lsn)
      Notification that offsets have been committed to Kafka up to the given LSN.
    • stop

      protected abstract void stop()
      Requests that this producer be stopped. This is normally a request coming from a PostgresConnectorTask instance
    • schema

      protected PostgresSchema schema()
    • topicNamingStrategy

      protected io.debezium.spi.topic.TopicNamingStrategy<TableId> topicNamingStrategy()
    • clock

      protected Clock clock()