Top Description Fields Constructors Methods
org.h2.mvstore.tx

pack-priv final Class RollbackDecisionMaker

extends MVMap.DecisionMaker<Record<?, ?>>
Class Inheritance
Imports
org.h2.mvstore.MVMap, org.h2.value.VersionedValue

Class RollbackDecisionMaker process undo log record during transaction rollback.
Author
Andrei Tokar

Field Summary

Modifier and TypeField and Description
private MVMap.Decision
private final TransactionStore.RollbackListener
private final TransactionStore
private final long
private final long
Inherited from org.h2.mvstore.MVMap.DecisionMaker:
DEFAULTPUTREMOVE

Constructor Summary

AccessConstructor and Description
pack-priv
RollbackDecisionMaker(TransactionStore store, long transactionId, long toLogId, TransactionStore.RollbackListener listener)

Method Summary

Modifier and TypeMethod and Description
public MVMap.Decision
decide(Record<K, V>
value currently exists in the map
existingValue
,
Record<K, V>
original input value
providedValue
)

Implements abstract org.h2.mvstore.MVMap.DecisionMaker.decide.

Makes a decision about how to proceed with the update.

public void
reset()

Overrides org.h2.mvstore.MVMap.DecisionMaker.reset.

Resets internal state (if any) of a this DecisionMaker to it's initial state.

public String
toString()

Overrides java.lang.Object.toString.

Returns a string representation of the object.

Inherited from org.h2.mvstore.MVMap.DecisionMaker:
decideselectValue

Field Detail

decisionback to summary
private MVMap.Decision decision
listenerback to summary
private final TransactionStore.RollbackListener listener
storeback to summary
private final TransactionStore store
toLogIdback to summary
private final long toLogId
transactionIdback to summary
private final long transactionId

Constructor Detail

RollbackDecisionMakerback to summary
pack-priv RollbackDecisionMaker(TransactionStore store, long transactionId, long toLogId, TransactionStore.RollbackListener listener)

Method Detail

decideback to summary
public MVMap.Decision decide(Record<K, V> existingValue, Record<K, V> providedValue)

Implements abstract org.h2.mvstore.MVMap.DecisionMaker.decide.

Doc from org.h2.mvstore.MVMap.DecisionMaker.decide.

Makes a decision about how to proceed with the update.

Parameters
existingValue:Record<K, V>

value currently exists in the map

providedValue:Record<K, V>

original input value

Returns:MVMap.Decision

PUT if a new value need to replace existing one or a new value to be inserted if there is none REMOVE if existing value should be deleted ABORT if update operation should be aborted or repeated later REPEAT if update operation should be repeated immediately

Annotations
@SuppressWarnings:unchecked, rawtypes
@Override
resetback to summary
public void reset()

Overrides org.h2.mvstore.MVMap.DecisionMaker.reset.

Doc from org.h2.mvstore.MVMap.DecisionMaker.reset.

Resets internal state (if any) of a this DecisionMaker to it's initial state. This method is invoked whenever concurrent update failure is encountered, so we can re-start update process.

Annotations
@Override
toStringback to summary
public String toString()

Overrides java.lang.Object.toString.

Doc from java.lang.Object.toString.

Returns a string representation of the object. Satisfying this method's contract implies a non-null result must be returned.

Returns:String

a string representation of the object

Annotations
@Override