|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.multiverse.stms.gamma.transactions.GammaTxn
org.multiverse.stms.gamma.transactions.fat.FatVariableLengthGammaTxn
public final class FatVariableLengthGammaTxn
| Field Summary | |
|---|---|
Tranlocal[] |
array
|
boolean |
hasReads
|
long |
localConflictCount
|
int |
size
|
| Fields inherited from class org.multiverse.stms.gamma.transactions.GammaTxn |
|---|
abortOnly, attempt, commitConflict, config, evaluatingCommute, hasWrites, listeners, pool, remainingTimeoutNs, retryListener, richmansMansConflictScan, status, transactionType |
| Fields inherited from interface org.multiverse.MultiverseConstants |
|---|
LOCKMODE_EXCLUSIVE, LOCKMODE_NONE, LOCKMODE_READ, LOCKMODE_WRITE, SHAKE_BUGS, SPIN_YIELD, TRACING_ENABLED |
| Constructor Summary | |
|---|---|
FatVariableLengthGammaTxn(GammaStm stm)
|
|
FatVariableLengthGammaTxn(GammaTxnConfig config)
|
|
| Method Summary | |
|---|---|
void |
abort()
Aborts this Txn. |
void |
attach(Tranlocal tranlocal,
int hash)
|
void |
commit()
Commits this Txn. |
Tranlocal |
getRefTranlocal(BaseGammaTxnRef ref)
Gets the Tranlocal for a specific AbstractGammaTxnRef. |
float |
getUsage()
|
void |
hardReset()
Does a hard reset of an aborted/committed transaction. |
int |
indexOf(BaseGammaTxnRef ref,
int hash)
|
void |
initLocalConflictCounter()
Initializes the local conflict counter if the transaction has a need for it. |
boolean |
isReadConsistent(Tranlocal justAdded)
|
Tranlocal |
locate(BaseGammaTxnRef o)
|
void |
prepare()
Prepares this transaction to be committed. |
void |
retry()
Retries the transaction. |
int |
size()
|
boolean |
softReset()
Does a soft reset of an aborted/committed transaction. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
public Tranlocal[] array
public int size
public boolean hasReads
public long localConflictCount
| Constructor Detail |
|---|
public FatVariableLengthGammaTxn(GammaStm stm)
public FatVariableLengthGammaTxn(GammaTxnConfig config)
| Method Detail |
|---|
public final void commit()
TxnTxn will always be aborted if the commit does not succeed.
Commit will not throw a ReadWriteConflict after the transaction is prepared.
So if prepared successfully, a commit will always succeed.
If there are TxnListeners (either normal ones or permanent ones) and they thrown a RuntimeException
or Error, this will be re-thrown. If a listener fails after the prepare/commit the transaction still is
committed.
commit in interface Txncommit in class GammaTxnpublic final void prepare()
TxnIt is very important that the transaction eventually commits or aborts, if it doesn't no other transaction reading/writing the committed resources, can't commit.
public final void abort()
TxnIf the Txn already is aborted, the call is ignored.
abort in interface Txnabort in class GammaTxnpublic final Tranlocal locate(BaseGammaTxnRef o)
locate in class GammaTxnpublic final Tranlocal getRefTranlocal(BaseGammaTxnRef ref)
GammaTxn
getRefTranlocal in class GammaTxnref - the AbstractGammaTxnRef
public final void retry()
TxnRetryError
is thrown which is caught by the TxnExecutor.
public final boolean softReset()
GammaTxn
softReset in class GammaTxnpublic final void hardReset()
GammaTxn
hardReset in class GammaTxnpublic void initLocalConflictCounter()
GammaTxn
initLocalConflictCounter in class GammaTxnpublic final boolean isReadConsistent(Tranlocal justAdded)
isReadConsistent in class GammaTxnpublic final float getUsage()
public final int size()
public final int indexOf(BaseGammaTxnRef ref,
int hash)
public final void attach(Tranlocal tranlocal,
int hash)
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||