Class ConflictResolver
java.lang.Object
com.gigaspaces.cluster.replication.gateway.conflict.ConflictResolver
- Direct Known Subclasses:
DefaultConflictResolver
A base class for a gateway replication Sink component conflict resolver. An appropriate method is
invoked for the following conflicts:
1. DataConflict - conflicts caused by
write/update/take operation execution.
2. RegisterTypeDescriptorConflict - conflict
caused by a type registration operation execution.
3. AddIndexConflict - conflict
caused by an add indexes operation execution.
The conflict resolver will be called
if there is some conflict when attempting to apply the replication affect into the local space.
If the cause for the conflict is EntryLockedUnderTransactionConflict, there will be an
automatic retry of the operation according to predefined configuration. In such case the conflict
resolver is invoked only after the amount of configurable operation retries has exceeded and the
EntryLockedUnderTransactionConflict conflict still occurs.
- Since:
- 8.0.3
- Author:
- eitany
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidonAddIndexConflict(String sourceGatewayName, AddIndexConflict conflict) Invoked after anAddIndexConflictoccurred.voidonDataConflict(String sourceGatewayName, DataConflict conflict) Invoked after aDataConflictoccurred.voidonRegisterTypeDescriptorConflict(String sourceGatewayName, RegisterTypeDescriptorConflict conflict) Invoked after aRegisterTypeDescriptorConflictoccurred.
-
Constructor Details
-
ConflictResolver
public ConflictResolver()
-
-
Method Details
-
onDataConflict
Invoked after aDataConflictoccurred. The default behavior of the conflict resolver is to abort all the operation that exists inside the providedDataConflict.- Parameters:
sourceGatewayName- The source gateway name the operations were replicated from.conflict- TheDataConflictinstance representing the conflict.
-
onRegisterTypeDescriptorConflict
public void onRegisterTypeDescriptorConflict(String sourceGatewayName, RegisterTypeDescriptorConflict conflict) Invoked after aRegisterTypeDescriptorConflictoccurred.- Parameters:
sourceGatewayName- The source gateway name the operation was replicated from.conflict- TheRegisterTypeDescriptorConflictinstance representing the conflict.
-
onAddIndexConflict
Invoked after anAddIndexConflictoccurred.- Parameters:
sourceGatewayName- The source gateway name the operation was replicated from.conflict- TheAddIndexConflictinstance representing the conflict.
-