|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.hadoop.hbase.regionserver.ServerNonceManager
@InterfaceAudience.Private public class ServerNonceManager
Implementation of nonce manager that stores nonces in a hash map and cleans them up after some time; if nonce group/client ID is supplied, nonces are stored by client ID.
Field Summary | |
---|---|
static String |
HASH_NONCE_GRACE_PERIOD_KEY
|
Constructor Summary | |
---|---|
ServerNonceManager(org.apache.hadoop.conf.Configuration conf)
|
Method Summary | |
---|---|
Chore |
createCleanupChore(Stoppable stoppable)
Creates a chore that is used to clean up old nonces. |
void |
endOperation(long group,
long nonce,
boolean success)
Ends the operation started by startOperation. |
void |
reportOperationFromWal(long group,
long nonce,
long writeTime)
Reports the operation from WAL during replay. |
void |
setConflictWaitIterationMs(int conflictWaitIterationMs)
|
boolean |
startOperation(long group,
long nonce,
Stoppable stoppable)
Starts the operation if operation with such nonce has not already succeeded. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String HASH_NONCE_GRACE_PERIOD_KEY
Constructor Detail |
---|
public ServerNonceManager(org.apache.hadoop.conf.Configuration conf)
Method Detail |
---|
public void setConflictWaitIterationMs(int conflictWaitIterationMs)
public boolean startOperation(long group, long nonce, Stoppable stoppable) throws InterruptedException
group
- Nonce group.nonce
- Nonce.stoppable
- Stoppable that terminates waiting (if any) when the server is stopped.
InterruptedException
public void endOperation(long group, long nonce, boolean success)
group
- Nonce group.nonce
- Nonce.success
- Whether the operation has succeeded.public void reportOperationFromWal(long group, long nonce, long writeTime)
group
- Nonce group.nonce
- Nonce.writeTime
- Entry write time, used to ignore entries that are too old.public Chore createCleanupChore(Stoppable stoppable)
stoppable
- Stoppable for the chore.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |