|
IBM WebSphereTM eXtreme Scale, Release 8.6 API Specification |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface CollisionArbiter
Decides what value to store when there is a collision on multiple primaries. The output of the arbitrateCollision method must be consistent across all primaries. Inconsistencies in this implementation will result in inconsistencies in data.
A CollisionArbiter
implementation that also implements the ObjectGridLifecycleListener
interface will be automatically added as an EventListener
on the ObjectGrid
when the
arbiter is set on the object grid.
A CollisionArbiter may implement the ObjectGridPlugin
interface in order
to receive enhanced ObjectGrid plug-in lifecycle method calls. The plug-in is
also required to correctly implement each of the bean methods related to
introspection of its state (for example isInitialized()
,
isDestroyed()
, etc).
ObjectGrid.addEventListener(EventListener)
,
ObjectGrid.setCollisionArbiter(CollisionArbiter)
Nested Class Summary | |
---|---|
static class |
CollisionArbiter.Resolution
Marks how the collision should be resolved. |
Method Summary | |
---|---|
CollisionArbiter.Resolution |
arbitrateCollision(CollisionData collisionData)
Indicates that a revision event has discovered a write operation has occurred on two primaries simultaneously. |
void |
initialize(ObjectGrid grid)
Called when the ObjectGrid which this arbiter is attached to is initialized. |
Method Detail |
---|
void initialize(ObjectGrid grid)
grid
- The ObjectGrid that this arbiter is responsible for arbitrating collisions for.CollisionArbiter.Resolution arbitrateCollision(CollisionData collisionData)
Return value | Outcome |
---|---|
null |
Abstain, allow the default arbiter to make the decision. |
CollisionArbiter.Resolution.KEEP |
Keep the existing entry, throw away the collision entry. |
CollisionArbiter.Resolution.OVERRIDE |
Override the existing entry with the collision entry. |
CollisionArbiter.Resolution.REVISE |
Modify the entry either by merging the entries or removing the entry. |
Exception |
The revision transaction will be rolled back. No revision will be applied and a message will be logged. |
collisionData
- The data object that provides information about the collision.
|
IBM WebSphereTM eXtreme Scale, Release 8.6 API Specification |
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |