Interface KafkaConsumerService

All Superinterfaces:
AutoCloseable, Closeable

public interface KafkaConsumerService extends Closeable
Kafka Consumer Service must be closed to avoid leaking connection resources
  • Method Details

    • commit

      void commit(PollingSummary pollingSummary)
      Commit record information to Kafka Brokers
      Parameters:
      pollingSummary - Polling Summary information to be committed
    • rollback

      void rollback()
      Rolls back the offsets of the records so that any records that have been polled since the last commit are re-polled
    • isClosed

      boolean isClosed()
      Returns:
      true if the service is closed; false otherwise
    • poll

      Iterable<ByteRecord> poll(Duration maxWaitDuration)
      Poll Subscriptions for Records
      Returns:
      Stream of Records or empty when none returned
    • getPartitionStates

      List<PartitionState> getPartitionStates()
      Get Partition State information for subscription
      Returns:
      List of Partition State information