Interface SnapshotSentinel

All Known Implementing Classes:
DisabledTableSnapshotHandler, EnabledTableSnapshotHandler, TakeSnapshotHandler

@Private @Unstable public interface SnapshotSentinel
Watch the current snapshot under process
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Actively cancel a running snapshot.
    long
    Returns -1 if the snapshot is in progress, otherwise the completion timestamp.
    Get the exception that caused the snapshot to fail, if the snapshot has failed.
    org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos.SnapshotDescription
    Returns the description of the snapshot being run
    boolean
    Check to see if the snapshot is finished, where finished may be success or failure.
    void
    Rethrow the exception returned by getExceptionIfFailed().
  • Method Details

    • isFinished

      boolean isFinished()
      Check to see if the snapshot is finished, where finished may be success or failure.
      Returns:
      false if the snapshot is still in progress, true if the snapshot has finished
    • getCompletionTimestamp

      Returns -1 if the snapshot is in progress, otherwise the completion timestamp.
    • cancel

      void cancel(String why)
      Actively cancel a running snapshot.
      Parameters:
      why - Reason for cancellation.
    • getSnapshot

      org.apache.hadoop.hbase.shaded.protobuf.generated.SnapshotProtos.SnapshotDescription getSnapshot()
      Returns the description of the snapshot being run
    • getExceptionIfFailed

      Get the exception that caused the snapshot to fail, if the snapshot has failed.
      Returns:
      ForeignException that caused the snapshot to fail, or null if the snapshot is still in progress or has succeeded
    • rethrowExceptionIfFailed

      Rethrow the exception returned by getExceptionIfFailed(). If there is no exception this is a no-op.
      Throws:
      ForeignException - all exceptions from remote sources are procedure exceptions