public static class MergePolicy.UnsupportedMergePolicy extends Object implements EntryMergePolicy
Constructor and Description |
---|
UnsupportedMergePolicy() |
Modifier and Type | Method and Description |
---|---|
CacheEntry |
merge(CacheEntry preferredEntry,
List otherEntries)
This method is called by
ConflictManager.resolveConflicts() for each conflict discovered to determine
which CacheEntry should be utilised. |
public CacheEntry merge(CacheEntry preferredEntry, List otherEntries)
EntryMergePolicy
ConflictManager.resolveConflicts()
for each conflict discovered to determine
which CacheEntry
should be utilised. This merge policy is used when a user explicitly calls ConflictManager.resolveConflicts()
as well as when a partition merge occurs with PartitionHandling.ALLOW_READ_WRITES
set.
In the event of a partition merge, we define the preferred partition as the partition whom's coordinator is coordinating
the current merge.merge
in interface EntryMergePolicy
preferredEntry
- During a partition merge, the preferredEntry is the primary replica of a CacheEntry stored
in the partition that contains the most nodes or if partitions are equal the one with the
largest topologyId. In the event of overlapping partitions, i.e. a node A is present in the
topology of both partitions {A}, {A,B,C}, we pick {A} as the preferred partition as it will
have the higher topologId because the other partition's topology is behind.
During a non-merge call to ConflictManager.resolveConflicts()
, the preferredEntry is
simply the primary owner of an entryotherEntries
- a List
of all other CacheEntry
associated with a given Key.CacheEntry
to be utilised across the cluster, or null if all entries for a key should be
removed.Copyright © 2021 JBoss by Red Hat. All rights reserved.