Enum WALTailingReader.State

java.lang.Object
java.lang.Enum<WALTailingReader.State>
org.apache.hadoop.hbase.wal.WALTailingReader.State
All Implemented Interfaces:
Serializable, Comparable<WALTailingReader.State>
Enclosing interface:
WALTailingReader

  • Enum Constant Summary

    Enum Constants
    Enum Constant
    Description
    This means we reach the EOF and the upper layer need to reset to see if there is more data.
    Mostly the same with the above EOF_AND_RESET, the difference is that here we also mess up the compression dictionary when reading data, so the upper layer should also clear the compression context when reseting, which means when calling resetTo method, we need to skip to the position instead of just seek to, which will impact performance.
    This means the WAL file has a trailer and we have reached it, which means we have finished reading this file normally
    This means we meet an error so the upper layer need to reset to read again
    Mostly the same with the above ERROR_AND_RESET, the difference is that here we also mess up the compression dictionary when reading data, so the upper layer should also clear the compression context when reseting, which means when calling resetTo method, we need to skip to the position instead of just seek to, which will impact performance.
    This means we read an Entry without any error
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    A dummy result for returning, as except NORMAL, for other state we do not need to provide fields other than state in the returned WALTailingReader.Result.
  • Constructor Summary

    Constructors
    Modifier
    Constructor
    Description
    private
     
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    eof()
     
     
    boolean
     
    Returns the enum constant of this type with the specified name.
    Returns an array containing the constants of this enum type, in the order they are declared.

    Methods inherited from class java.lang.Enum

    clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf

    Methods inherited from class java.lang.Object

    getClass, notify, notifyAll, wait, wait, wait
  • Enum Constant Details

    • NORMAL

      public static final WALTailingReader.State NORMAL
      This means we read an Entry without any error
    • EOF_WITH_TRAILER

      This means the WAL file has a trailer and we have reached it, which means we have finished reading this file normally
    • ERROR_AND_RESET

      This means we meet an error so the upper layer need to reset to read again
    • ERROR_AND_RESET_COMPRESSION

      Mostly the same with the above ERROR_AND_RESET, the difference is that here we also mess up the compression dictionary when reading data, so the upper layer should also clear the compression context when reseting, which means when calling resetTo method, we need to skip to the position instead of just seek to, which will impact performance.
    • EOF_AND_RESET

      This means we reach the EOF and the upper layer need to reset to see if there is more data. Notice that this does not mean that there is necessarily more data, the upper layer should determine whether they need to reset and read again.
    • EOF_AND_RESET_COMPRESSION

      Mostly the same with the above EOF_AND_RESET, the difference is that here we also mess up the compression dictionary when reading data, so the upper layer should also clear the compression context when reseting, which means when calling resetTo method, we need to skip to the position instead of just seek to, which will impact performance. The implementation should try its best to not fall into this situation.
  • Field Details

  • Constructor Details

  • Method Details

    • values

      public static WALTailingReader.State[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static WALTailingReader.State valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null
    • getResult

    • resetCompression

      public boolean resetCompression()
    • eof

      public boolean eof()