HBASE-24166 Duplicate implementation for acquireLock between CreateTableProcedure and its parent class (#1486)

Signed-off-by: Viraj Jasani <vjasani@apache.org>
Signed-off-by: Duo Zhang <zhangduo@apache.org>
This commit is contained in:
XinSun 2020-04-18 10:30:12 +08:00 committed by GitHub
parent 2c8d104d71
commit 8e5c6da3f0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 0 additions and 16 deletions

View File

@ -239,14 +239,6 @@ public class CreateTableProcedure
return super.waitInitialized(env);
}
@Override
protected LockState acquireLock(final MasterProcedureEnv env) {
if (env.getProcedureScheduler().waitTableExclusiveLock(this, getTableName())) {
return LockState.LOCK_EVENT_WAIT;
}
return LockState.LOCK_ACQUIRED;
}
private boolean prepareCreate(final MasterProcedureEnv env) throws IOException {
final TableName tableName = getTableName();
if (MetaTableAccessor.tableExists(env.getMasterServices().getConnection(), tableName)) {

View File

@ -115,14 +115,6 @@ public class InitMetaProcedure extends AbstractStateMachineTableProcedure<InitMe
return false;
}
@Override
protected LockState acquireLock(MasterProcedureEnv env) {
if (env.getProcedureScheduler().waitTableExclusiveLock(this, getTableName())) {
return LockState.LOCK_EVENT_WAIT;
}
return LockState.LOCK_ACQUIRED;
}
@Override
protected void rollbackState(MasterProcedureEnv env, InitMetaState state)
throws IOException, InterruptedException {