Interface Consumer

All Superinterfaces:
AutoCloseable

public interface Consumer extends AutoCloseable
API to consume messages from a RabbitMQ Stream.

Instances are configured and created with a ConsumerBuilder.

See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Close the consumer.
    void
    store(long offset)
    Store the offset.
    long
    The stored offset for this named consumer on the configured stream.
  • Method Details

    • store

      void store(long offset)
      Store the offset.
      Parameters:
      offset -
    • close

      void close()
      Close the consumer.
      Specified by:
      close in interface AutoCloseable
    • storedOffset

      long storedOffset()
      The stored offset for this named consumer on the configured stream.
      Returns:
      stored offset
      Throws:
      NoOffsetException - if no offset is stored for this name on the stream
      Since:
      0.6.0