public abstract static class ClusteringDependentLogic.AbstractClusteringDependentLogic extends Object implements ClusteringDependentLogic
ClusteringDependentLogic.AbstractClusteringDependentLogic, ClusteringDependentLogic.DistributionLogic, ClusteringDependentLogic.InvalidationLogic, ClusteringDependentLogic.LocalLogic, ClusteringDependentLogic.ReplicationLogic
Modifier and Type | Field and Description |
---|---|
protected DataContainer |
dataContainer |
protected CacheNotifier |
notifier |
protected boolean |
totalOrder |
LOCAL_MODE_ADDRESS
Constructor and Description |
---|
ClusteringDependentLogic.AbstractClusteringDependentLogic() |
Modifier and Type | Method and Description |
---|---|
protected void |
commitCacheEntry(CacheEntry entry,
Metadata metadata) |
EntryVersionsMap |
createNewVersionsAndCheckForWriteSkews(VersionGenerator versionGenerator,
TxInvocationContext context,
VersionedPrepareCommand prepareCommand) |
void |
init(DataContainer dataContainer,
CacheNotifier notifier,
Configuration configuration) |
protected abstract WriteSkewHelper.KeySpecificLogic |
initKeySpecificLogic(boolean totalOrder) |
boolean |
lock(Object key,
boolean noWaitTime)
Acquires internal lock to interact with DataContainer
|
protected void |
notifyCommitEntry(boolean created,
boolean removed,
boolean evicted,
CacheEntry entry,
InvocationContext ctx,
FlagAffectedCommand command) |
void |
unlock(Object key) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
commitEntry, getAddress, getOwners, getOwners, getPrimaryOwner, localNodeIsOwner, localNodeIsPrimaryOwner
protected DataContainer dataContainer
protected CacheNotifier notifier
protected boolean totalOrder
public ClusteringDependentLogic.AbstractClusteringDependentLogic()
public void init(DataContainer dataContainer, CacheNotifier notifier, Configuration configuration)
public EntryVersionsMap createNewVersionsAndCheckForWriteSkews(VersionGenerator versionGenerator, TxInvocationContext context, VersionedPrepareCommand prepareCommand)
createNewVersionsAndCheckForWriteSkews
in interface ClusteringDependentLogic
protected abstract WriteSkewHelper.KeySpecificLogic initKeySpecificLogic(boolean totalOrder)
protected void notifyCommitEntry(boolean created, boolean removed, boolean evicted, CacheEntry entry, InvocationContext ctx, FlagAffectedCommand command)
public final boolean lock(Object key, boolean noWaitTime) throws InterruptedException
ClusteringDependentLogic
lock
in interface ClusteringDependentLogic
noWaitTime
- if true
, it tries to acquire the lock without waitingtrue
if the lock was acquired.InterruptedException
- if interrupted while waiting.public final void unlock(Object key)
unlock
in interface ClusteringDependentLogic
protected final void commitCacheEntry(CacheEntry entry, Metadata metadata)
Copyright © 2014 JBoss, a division of Red Hat. All Rights Reserved.