public class ProcedureTestingUtility extends Object
Modifier and Type | Class and Description |
---|---|
static class |
ProcedureTestingUtility.TestProcedure |
Modifier and Type | Method and Description |
---|---|
static void |
assertIsAbortException(ProcedureInfo result) |
static void |
assertIsIllegalArgumentException(ProcedureInfo result) |
static void |
assertIsTimeoutException(ProcedureInfo result) |
static <TEnv> void |
assertProcNotFailed(ProcedureExecutor<TEnv> procExecutor,
long procId) |
static void |
assertProcNotFailed(ProcedureInfo result) |
static <TEnv> void |
assertProcNotYetCompleted(ProcedureExecutor<TEnv> procExecutor,
long procId) |
static ProcedureStore |
createStore(Configuration conf,
FileSystem fs,
Path baseDir) |
static WALProcedureStore |
createWalStore(Configuration conf,
FileSystem fs,
Path logDir) |
static Throwable |
getExceptionCause(ProcedureInfo procInfo) |
static <TEnv> void |
restart(ProcedureExecutor<TEnv> procExecutor) |
static <TEnv> void |
restart(ProcedureExecutor<TEnv> procExecutor,
Runnable beforeStartAction) |
static <TEnv> void |
setKillAndToggleBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor,
boolean value) |
static <TEnv> void |
setKillBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor,
boolean value) |
static <TEnv> void |
setToggleKillBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor,
boolean value) |
static <TEnv> long |
submitAndWait(ProcedureExecutor<TEnv> procExecutor,
Procedure proc) |
static <TEnv> void |
toggleKillBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor) |
static <TEnv> void |
waitNoProcedureRunning(ProcedureExecutor<TEnv> procExecutor) |
static <TEnv> void |
waitProcedure(ProcedureExecutor<TEnv> procExecutor,
long procId) |
public static ProcedureStore createStore(Configuration conf, FileSystem fs, Path baseDir) throws IOException
IOException
public static WALProcedureStore createWalStore(Configuration conf, FileSystem fs, Path logDir) throws IOException
IOException
public static <TEnv> void restart(ProcedureExecutor<TEnv> procExecutor) throws Exception
Exception
public static <TEnv> void restart(ProcedureExecutor<TEnv> procExecutor, Runnable beforeStartAction) throws Exception
Exception
public static <TEnv> void setKillBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor, boolean value)
public static <TEnv> void setToggleKillBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor, boolean value)
public static <TEnv> void toggleKillBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor)
public static <TEnv> void setKillAndToggleBeforeStoreUpdate(ProcedureExecutor<TEnv> procExecutor, boolean value)
public static <TEnv> long submitAndWait(ProcedureExecutor<TEnv> procExecutor, Procedure proc)
public static <TEnv> void waitProcedure(ProcedureExecutor<TEnv> procExecutor, long procId)
public static <TEnv> void waitNoProcedureRunning(ProcedureExecutor<TEnv> procExecutor)
public static <TEnv> void assertProcNotYetCompleted(ProcedureExecutor<TEnv> procExecutor, long procId)
public static <TEnv> void assertProcNotFailed(ProcedureExecutor<TEnv> procExecutor, long procId)
public static void assertProcNotFailed(ProcedureInfo result)
public static void assertIsAbortException(ProcedureInfo result)
public static void assertIsTimeoutException(ProcedureInfo result)
public static void assertIsIllegalArgumentException(ProcedureInfo result)
public static Throwable getExceptionCause(ProcedureInfo procInfo)