Class TestSplitWALManager.FakeServerProcedure

java.lang.Object
org.apache.hadoop.hbase.procedure2.Procedure<TEnvironment>
org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
org.apache.hadoop.hbase.master.TestSplitWALManager.FakeServerProcedure
All Implemented Interfaces:
Comparable<org.apache.hadoop.hbase.procedure2.Procedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv>>, org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface
Enclosing class:
TestSplitWALManager

public static final class TestSplitWALManager.FakeServerProcedure extends org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState> implements org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.apache.hadoop.hbase.procedure2.StateMachineProcedure

    org.apache.hadoop.hbase.procedure2.StateMachineProcedure.Flow

    Nested classes/interfaces inherited from class org.apache.hadoop.hbase.procedure2.Procedure

    org.apache.hadoop.hbase.procedure2.Procedure.LockState

    Nested classes/interfaces inherited from interface org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface

    org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface.ServerOperationType
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
     
    private org.apache.hadoop.hbase.ServerName
     
    private boolean
     
    private org.apache.hadoop.hbase.ServerName
     

    Fields inherited from class org.apache.hadoop.hbase.procedure2.StateMachineProcedure

    stateCount

    Fields inherited from class org.apache.hadoop.hbase.procedure2.Procedure

    NO_PROC_ID, NO_TIMEOUT
  • Constructor Summary

    Constructors
    Constructor
    Description
     
    FakeServerProcedure(org.apache.hadoop.hbase.ServerName serverName)
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected boolean
    abort(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env)
     
    void
     
    protected void
    deserializeStateData(org.apache.hadoop.hbase.procedure2.ProcedureStateSerializer serializer)
     
    protected org.apache.hadoop.hbase.procedure2.StateMachineProcedure.Flow
    executeFromState(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env, org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState state)
     
    protected org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState
     
    org.apache.hadoop.hbase.ServerName
     
    org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface.ServerOperationType
     
    protected org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState
    getState(int stateId)
     
    protected int
    getStateId(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState state)
     
    boolean
     
    protected boolean
    holdLock(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env)
     
    boolean
     
    boolean
     
    protected void
    rollback(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env)
     
    protected void
    rollbackState(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env, org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState state)
     
    protected void
    serializeStateData(org.apache.hadoop.hbase.procedure2.ProcedureStateSerializer serializer)
     

    Methods inherited from class org.apache.hadoop.hbase.procedure2.StateMachineProcedure

    addChildProcedure, execute, failIfAborted, getCurrentState, getCurrentStateId, getCycles, isEofState, isRollbackSupported, isRollbackSupported, isYieldAfterExecutionStep, isYieldBeforeExecuteFromState, setNextState, toStringState

    Methods inherited from class org.apache.hadoop.hbase.procedure2.Procedure

    acquireLock, addStackIndex, afterReplay, beforeReplay, bypass, compareTo, completionCleanup, doExecute, doRollback, elapsedTime, getChildrenLatch, getException, getLastUpdate, getNonceKey, getOwner, getParentProcId, getProcedureMetrics, getProcId, getProcIdHashCode, getProcName, getResult, getRootProcedureId, getRootProcId, getStackIndexes, getState, getSubmittedTime, getTimeout, getTimeoutTimestamp, hasChildren, hasException, hasLock, hasOwner, hasParent, hasTimeout, haveSameParent, incChildrenLatch, isBypass, isFailed, isFinished, isInitializing, isLockedWhenLoading, isRunnable, isSuccess, isWaiting, releaseLock, removeStackIndex, setAbortFailure, setChildrenLatch, setExecuted, setFailure, setFailure, setLastUpdate, setNonceKey, setOwner, setOwner, setParentProcId, setProcId, setResult, setRootProcId, setStackIndexes, setState, setSubmittedTime, setTimeout, setTimeoutFailure, shouldWaitClientAck, skipPersistence, suspend, toString, toStringClass, toStringClassDetails, toStringDetails, toStringSimpleSB, updateMetricsOnFinish, updateMetricsOnSubmit, updateTimestamp, waitInitialized, wasExecuted

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Field Details

  • Constructor Details

  • Method Details

    • getServerName

      public org.apache.hadoop.hbase.ServerName getServerName()
      Specified by:
      getServerName in interface org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface
    • hasMetaTableRegion

      public boolean hasMetaTableRegion()
      Specified by:
      hasMetaTableRegion in interface org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface
    • getServerOperationType

      public org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface.ServerOperationType getServerOperationType()
      Specified by:
      getServerOperationType in interface org.apache.hadoop.hbase.master.procedure.ServerProcedureInterface
    • executeFromState

      protected org.apache.hadoop.hbase.procedure2.StateMachineProcedure.Flow executeFromState(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env, org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState state) throws org.apache.hadoop.hbase.procedure2.ProcedureSuspendedException, org.apache.hadoop.hbase.procedure2.ProcedureYieldException, InterruptedException
      Specified by:
      executeFromState in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
      Throws:
      org.apache.hadoop.hbase.procedure2.ProcedureSuspendedException
      org.apache.hadoop.hbase.procedure2.ProcedureYieldException
      InterruptedException
    • isWorkerAcquired

      public boolean isWorkerAcquired()
    • isTriedToAcquire

      public boolean isTriedToAcquire()
    • countDown

      public void countDown()
    • rollbackState

      protected void rollbackState(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env, org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState state) throws IOException, InterruptedException
      Specified by:
      rollbackState in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
      Throws:
      IOException
      InterruptedException
    • getState

      protected org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState getState(int stateId)
      Specified by:
      getState in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
    • getStateId

      protected int getStateId(org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState state)
      Specified by:
      getStateId in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
    • getInitialState

      protected org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState getInitialState()
      Specified by:
      getInitialState in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
    • holdLock

      protected boolean holdLock(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env)
      Overrides:
      holdLock in class org.apache.hadoop.hbase.procedure2.Procedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv>
    • rollback

      protected void rollback(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env) throws IOException, InterruptedException
      Overrides:
      rollback in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
      Throws:
      IOException
      InterruptedException
    • abort

      protected boolean abort(org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv env)
      Overrides:
      abort in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
    • serializeStateData

      protected void serializeStateData(org.apache.hadoop.hbase.procedure2.ProcedureStateSerializer serializer) throws IOException
      Overrides:
      serializeStateData in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
      Throws:
      IOException
    • deserializeStateData

      protected void deserializeStateData(org.apache.hadoop.hbase.procedure2.ProcedureStateSerializer serializer) throws IOException
      Overrides:
      deserializeStateData in class org.apache.hadoop.hbase.procedure2.StateMachineProcedure<org.apache.hadoop.hbase.master.procedure.MasterProcedureEnv,org.apache.hadoop.hbase.shaded.protobuf.generated.MasterProcedureProtos.SplitWALState>
      Throws:
      IOException