Interface ClusteringDependentLogic
-
- All Known Implementing Classes:
ClusteringDependentLogic.AbstractClusteringDependentLogic
,ClusteringDependentLogic.DistributionLogic
,ClusteringDependentLogic.InvalidationLogic
,ClusteringDependentLogic.LocalLogic
,ClusteringDependentLogic.ReplicationLogic
,ClusteringDependentLogic.ScatteredLogic
public interface ClusteringDependentLogic
Abstractization for logic related to different clustering modes: replicated or distributed. This implements the Bridge pattern as described by the GoF: this plays the role of the Implementor and various LockingInterceptors are the Abstraction.- Author:
- Mircea Markus, Pedro Ruivo
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static class
ClusteringDependentLogic.AbstractClusteringDependentLogic
static class
ClusteringDependentLogic.Commit
static class
ClusteringDependentLogic.DistributionLogic
This logic is used in distributed mode caches.static class
ClusteringDependentLogic.InvalidationLogic
This logic is used in invalidation mode caches.static class
ClusteringDependentLogic.LocalLogic
This logic is used in local mode caches.static class
ClusteringDependentLogic.ReplicationLogic
This logic is used in replicated mode caches.static class
ClusteringDependentLogic.ScatteredLogic
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Deprecated Methods Modifier and Type Method Description void
commitEntry(CacheEntry entry, org.infinispan.commands.FlagAffectedCommand command, InvocationContext ctx, Flag trackFlag, boolean l1Invalidation)
ClusteringDependentLogic.Commit
commitType(org.infinispan.commands.FlagAffectedCommand command, InvocationContext ctx, int segment, boolean removed)
Determines what type of commit this is.EntryVersionsMap
createNewVersionsAndCheckForWriteSkews(VersionGenerator versionGenerator, org.infinispan.context.impl.TxInvocationContext context, org.infinispan.commands.tx.VersionedPrepareCommand prepareCommand)
Address
getAddress()
LocalizedCacheTopology
getCacheTopology()
default Collection<Address>
getOwners(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().getWriteOwners(key)
instead.default Collection<Address>
getOwners(Collection<Object> keys)
Deprecated.Since 9.0, please usegetCacheTopology().getWriteOwners(keys)
instead.default Address
getPrimaryOwner(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().getDistributionInfo(key).primary()
instead.default boolean
localNodeIsOwner(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().isWriteOwner(key)
instead.default boolean
localNodeIsPrimaryOwner(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().getDistribution(key).isPrimary()
instead.
-
-
-
Method Detail
-
getCacheTopology
LocalizedCacheTopology getCacheTopology()
- Returns:
- information about the location of keys.
-
localNodeIsOwner
@Deprecated default boolean localNodeIsOwner(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().isWriteOwner(key)
instead.
-
localNodeIsPrimaryOwner
@Deprecated default boolean localNodeIsPrimaryOwner(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().getDistribution(key).isPrimary()
instead.
-
getPrimaryOwner
@Deprecated default Address getPrimaryOwner(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().getDistributionInfo(key).primary()
instead.
-
commitEntry
void commitEntry(CacheEntry entry, org.infinispan.commands.FlagAffectedCommand command, InvocationContext ctx, Flag trackFlag, boolean l1Invalidation)
-
commitType
ClusteringDependentLogic.Commit commitType(org.infinispan.commands.FlagAffectedCommand command, InvocationContext ctx, int segment, boolean removed)
Determines what type of commit this is. Whether we shouldn't commit, or if this is a commit due to owning the key or not- Parameters:
command
-ctx
-segment
- if 0 or greater assumes the underlying container is segmented.removed
-- Returns:
-
getOwners
@Deprecated default Collection<Address> getOwners(Collection<Object> keys)
Deprecated.Since 9.0, please usegetCacheTopology().getWriteOwners(keys)
instead.
-
getOwners
@Deprecated default Collection<Address> getOwners(Object key)
Deprecated.Since 9.0, please usegetCacheTopology().getWriteOwners(key)
instead.
-
createNewVersionsAndCheckForWriteSkews
EntryVersionsMap createNewVersionsAndCheckForWriteSkews(VersionGenerator versionGenerator, org.infinispan.context.impl.TxInvocationContext context, org.infinispan.commands.tx.VersionedPrepareCommand prepareCommand)
-
getAddress
Address getAddress()
-
-