Interface LogTailer<M extends Externalizable>

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      Collection<LogPartition> assignments()
      Returns the list of Log name, partitions tuples currently assigned to this tailer.
      void close()  
      boolean closed()
      Returns true if the tailer has been closed.
      void commit()
      Commit current positions for all partitions (last message offset returned by read).
      LogOffset commit​(LogPartition partition)
      Commit current position for the partition.
      Codec<M> getCodec()
      Returns the codec used to read the records.
      Name group()
      Returns the consumer group.
      LogOffset offsetForTimestamp​(LogPartition partition, long timestamp)
      Look up the offset for the given partition by timestamp.
      LogRecord<M> read​(Duration timeout)
      Read a message from assigned partitions within the timeout.
      void reset()
      Reset all committed positions for this group, next read will be done from beginning.
      void reset​(LogPartition partition)
      Reset the committed position for this group on this partition, next read for this partition will be done from the beginning.
      void seek​(LogOffset offset)
      Set the current position for a single partition.
      void toEnd()
      Set the current positions to the end of all partitions.
      void toLastCommitted()
      Set the current positions to previously committed positions.
      void toStart()
      Set the current positions to the beginning of all partitions.