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
Modifier and TypeFieldDescriptionstatic final int
static final String
static final int
static final String
static final int
static final String
private ProcedureCoordinator
private boolean
private static final org.slf4j.Logger
private MasterServices
static final String
static final String
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
checkPermissions
(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc, AccessChecker accessChecker, User user) Check for required permissions before executing the procedure.void
execProcedure
(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) Execute a distributed procedure on clusterReturn the unique signature of the procedure.void
initialize
(MasterServices master, MetricsMaster metricsMaster) Initialize a globally barriered procedure for master.private boolean
boolean
isProcedureDone
(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) Check if the procedure is finished successfullyboolean
Returns True ifStoppable.stop(String)
has been closed.void
Stop this service.Methods inherited from class org.apache.hadoop.hbase.procedure.MasterProcedureManager
execProcedureWithRet
Methods 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:Stoppable
Stop this service. Implementers should favor logging errors over throwing RuntimeExceptions.- Parameters:
why
- Why we're stopping.
-
isStopped
Description copied from interface:Stoppable
Returns True ifStoppable.stop(String)
has been closed. -
initialize
public void initialize(MasterServices master, MetricsMaster metricsMaster) throws IOException, UnsupportedOperationException Description copied from class:MasterProcedureManager
Initialize a globally barriered procedure for master.- Specified by:
initialize
in classMasterProcedureManager
- Parameters:
master
- Master service interface- Throws:
IOException
UnsupportedOperationException
-
getProcedureSignature
Description copied from class:ProcedureManager
Return 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:
getProcedureSignature
in classProcedureManager
-
execProcedure
public void execProcedure(org.apache.hadoop.hbase.shaded.protobuf.generated.HBaseProtos.ProcedureDescription desc) throws IOException Description copied from class:MasterProcedureManager
Execute a distributed procedure on cluster- Overrides:
execProcedure
in 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:MasterProcedureManager
Check for required permissions before executing the procedure.- Specified by:
checkPermissions
in 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:MasterProcedureManager
Check if the procedure is finished successfully- Specified by:
isProcedureDone
in classMasterProcedureManager
- Parameters:
desc
- Procedure description- Returns:
- true if the specified procedure is finished successfully
-