@InterfaceAudience.Private @InterfaceStability.Evolving public final class MasterProcedureUtil extends Object
Modifier and Type | Class and Description |
---|---|
static class |
MasterProcedureUtil.NonceProcedureRunnable
Helper Runnable used in conjunction with submitProcedure() to deal with
submitting procs with nonce.
|
Modifier and Type | Method and Description |
---|---|
static int |
getServerPriority(ServerProcedureInterface proc)
Return the priority for the given procedure.
|
static int |
getTablePriority(TableName tableName)
Return the priority for the given table.
|
static long |
submitProcedure(MasterProcedureUtil.NonceProcedureRunnable runnable)
Helper used to deal with submitting procs with nonce.
|
static RPCProtos.UserInformation |
toProtoUserInfo(User user) |
static User |
toUserInfo(RPCProtos.UserInformation userInfoProto) |
static IOException |
unwrapRemoteIOException(Procedure proc)
This is a version of unwrapRemoteIOException that can do DoNotRetryIOE.
|
static boolean |
validateProcedureWALFilename(String filename)
A Procedure WAL file name is of the format: pv-<wal-id>.log where wal-id is 20 digits.
|
public static RPCProtos.UserInformation toProtoUserInfo(User user)
public static User toUserInfo(RPCProtos.UserInformation userInfoProto)
public static long submitProcedure(MasterProcedureUtil.NonceProcedureRunnable runnable) throws IOException
long procId = MasterProcedureUtil.submitProcedure(
new NonceProcedureRunnable(procExec, nonceGroup, nonce) {
@Override
public void run() {
cpHost.preOperation();
submitProcedure(new MyProc());
cpHost.postOperation();
}
});
IOException
public static boolean validateProcedureWALFilename(String filename)
filename
- name of the file to validatepublic static int getTablePriority(TableName tableName)
public static int getServerPriority(ServerProcedureInterface proc)
public static IOException unwrapRemoteIOException(Procedure proc)
Copyright © 2007–2019 Cloudera. All rights reserved.