Class LogRollMasterProcedureManager
java.lang.Object
org.apache.hadoop.hbase.procedure.ProcedureManager
org.apache.hadoop.hbase.procedure.MasterProcedureManager
org.apache.hadoop.hbase.backup.master.LogRollMasterProcedureManager
- All Implemented Interfaces:
Stoppable
Master procedure manager for coordinated cluster-wide WAL roll operation, which is run during
backup operation, see
MasterProcedureManager and RegionServerProcedureManager-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final Stringstatic final intstatic final Stringstatic final intstatic final Stringprivate ProcedureCoordinatorprivate booleanprivate static final org.slf4j.Loggerprivate MasterServicesstatic final Stringstatic final String -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcheckPermissions(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc, AccessChecker accessChecker, User user) Check for required permissions before executing the procedure.voidexecProcedure(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) Execute a distributed procedure on clusterReturn the unique signature of the procedure.voidinitialize(MasterServices master, MetricsMaster metricsMaster) Initialize a globally barriered procedure for master.private booleanbooleanisProcedureDone(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) Check if the procedure is finished successfullybooleanReturns True ifStoppable.stop(String)has been closed.voidStop this service.Methods inherited from class org.apache.hadoop.hbase.procedure.MasterProcedureManager
execProcedureWithRetMethods inherited from class org.apache.hadoop.hbase.procedure.ProcedureManager
equals, hashCode
-
Field Details
-
LOG
-
ROLLLOG_PROCEDURE_SIGNATURE
- See Also:
-
ROLLLOG_PROCEDURE_NAME
- See Also:
-
BACKUP_WAKE_MILLIS_KEY
- See Also:
-
BACKUP_TIMEOUT_MILLIS_KEY
- See Also:
-
BACKUP_POOL_THREAD_NUMBER_KEY
- See Also:
-
BACKUP_WAKE_MILLIS_DEFAULT
- See Also:
-
BACKUP_TIMEOUT_MILLIS_DEFAULT
- See Also:
-
BACKUP_POOL_THREAD_NUMBER_DEFAULT
- See Also:
-
master
-
coordinator
-
done
-
-
Constructor Details
-
LogRollMasterProcedureManager
public LogRollMasterProcedureManager()
-
-
Method Details
-
stop
Description copied from interface:StoppableStop this service. Implementers should favor logging errors over throwing RuntimeExceptions.- Parameters:
why- Why we're stopping.
-
isStopped
Description copied from interface:StoppableReturns True ifStoppable.stop(String)has been closed. -
initialize
public void initialize(MasterServices master, MetricsMaster metricsMaster) throws IOException, UnsupportedOperationException Description copied from class:MasterProcedureManagerInitialize a globally barriered procedure for master.- Specified by:
initializein classMasterProcedureManager- Parameters:
master- Master service interface- Throws:
IOExceptionUnsupportedOperationException
-
getProcedureSignature
Description copied from class:ProcedureManagerReturn the unique signature of the procedure. This signature uniquely identifies the procedure. By default, this signature is the string used in the procedure controller (i.e., the root ZK node name for the procedure)- Specified by:
getProcedureSignaturein classProcedureManager
-
execProcedure
public void execProcedure(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) throws IOException Description copied from class:MasterProcedureManagerExecute a distributed procedure on cluster- Overrides:
execProcedurein classMasterProcedureManager- Parameters:
desc- Procedure description- Throws:
IOException
-
checkPermissions
public void checkPermissions(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc, AccessChecker accessChecker, User user) throws IOException Description copied from class:MasterProcedureManagerCheck for required permissions before executing the procedure.- Specified by:
checkPermissionsin classMasterProcedureManager- Throws:
IOException- if permissions requirements are not met.
-
isBackupEnabled
-
isProcedureDone
public boolean isProcedureDone(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) Description copied from class:MasterProcedureManagerCheck if the procedure is finished successfully- Specified by:
isProcedureDonein classMasterProcedureManager- Parameters:
desc- Procedure description- Returns:
- true if the specified procedure is finished successfully
-