@InterfaceAudience.Private public abstract class SnapshotTask extends Object implements ForeignExceptionSnare, Callable<Void>
Modifier and Type | Field and Description |
---|---|
protected ForeignExceptionDispatcher |
errorMonitor |
protected HBaseProtos.SnapshotDescription |
snapshot |
Constructor and Description |
---|
SnapshotTask(HBaseProtos.SnapshotDescription snapshot,
ForeignExceptionDispatcher monitor) |
Modifier and Type | Method and Description |
---|---|
ForeignException |
getException()
Get the value of the captured exception.
|
boolean |
hasException()
Non-exceptional form of
ForeignExceptionSnare.rethrowException() . |
void |
rethrowException()
Rethrow an exception currently held by the
ForeignExceptionSnare . |
void |
snapshotFailure(String message,
Exception e) |
protected final HBaseProtos.SnapshotDescription snapshot
protected final ForeignExceptionDispatcher errorMonitor
public SnapshotTask(HBaseProtos.SnapshotDescription snapshot, ForeignExceptionDispatcher monitor)
snapshot
- Description of the snapshot we are going to operate onmonitor
- listener interested in failures to the snapshot caused by this operationpublic void rethrowException() throws ForeignException
ForeignExceptionSnare
ForeignExceptionSnare
. If there is
no exception this is a no-oprethrowException
in interface ForeignExceptionSnare
ForeignException
- all exceptions from remote sources are procedure exceptionspublic boolean hasException()
ForeignExceptionSnare
ForeignExceptionSnare.rethrowException()
. Checks to see if any
process to which the exception checkers is bound has created an error that
would cause a failure.hasException
in interface ForeignExceptionSnare
public ForeignException getException()
ForeignExceptionSnare
getException
in interface ForeignExceptionSnare
Copyright © 2013 The Apache Software Foundation. All rights reserved.