Class AbstractTableWalker

  • All Implemented Interfaces:
    TableWalker
    Direct Known Subclasses:
    RdbTableWalker

    public abstract class AbstractTableWalker
    extends Object
    implements TableWalker
    Iterator through a table.

    Iterates through partitions, can support partition filter (by time and/or value) and and also ranges on primary key.

    This class expects raw (byte[]) input for the primary key ranges.

    • Field Detail

      • log

        protected Log log
      • ascending

        protected final boolean ascending
      • follow

        protected final boolean follow
      • numRecordsRead

        protected long numRecordsRead
      • running

        protected volatile boolean running
    • Method Detail

      • iAscendingFinished

        protected boolean iAscendingFinished​(byte[] key,
                                             byte[] value,
                                             byte[] rangeEnd)
      • isDescendingFinished

        protected boolean isDescendingFinished​(byte[] key,
                                               byte[] value,
                                               byte[] rangeStart)
      • walkInterval

        protected abstract boolean walkInterval​(PartitionManager.Interval interval,
                                                DbRange range,
                                                TableVisitor visitor)
                                         throws YarchException
        Runs the data in a time interval (corresponding to a time partition) sending data only that conform with the start and end filters. Returns true if the stop condition is met
        Returns:
        returns true if the end condition has been reached.
        Throws:
        YarchException
      • isRunning

        protected boolean isRunning()