public enum GridDrReceiverCacheConflictResolverMode extends Enum<GridDrReceiverCacheConflictResolverMode>
Each cache entry has data center ID. In case cache update is performed and either old or new cache entry has data
center ID which differs from local data center ID defined by GridConfiguration.getDataCenterId(), then
we consider such situation as conflict.
If both entries participating in conflict have the same data cneter ID (i.e. they both were replicated from the same remote data center), then GridGain can potentially resolve this conflict automatically based on entry metadata.
But in case old and new entries have different data center IDs (i.e. in active-active scenario when cache is updated in both data centers participating in data center replication, or when cache is updated from multiple remote data centers), then explicit conflict resolution is required.
This enumeration provides several different strategies for conflict resolution.
| Enum Constant and Description |
|---|
DR_ALWAYS
GridGain will always delegate to conflict resolver.
|
DR_AUTO
GridGain will automatically resolve conflicts when possible (i.e.
|
| Modifier and Type | Method and Description |
|---|---|
static GridDrReceiverCacheConflictResolverMode |
fromOrdinal(int ord)
Efficiently gets enumerated value from its ordinal.
|
static GridDrReceiverCacheConflictResolverMode |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static GridDrReceiverCacheConflictResolverMode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final GridDrReceiverCacheConflictResolverMode DR_AUTO
GridDrReceiverCacheConflictResolver configured through
GridDrReceiverCacheConfiguration.getConflictResolver(). In case conflict resolver is not configured,
GridGain will overwrite old entry with a new one.
This mode is default.
public static final GridDrReceiverCacheConflictResolverMode DR_ALWAYS
In this mode GridDrReceiverCacheConfiguration.getConflictResolver() is mandatory.
public static GridDrReceiverCacheConflictResolverMode[] values()
for (GridDrReceiverCacheConflictResolverMode c : GridDrReceiverCacheConflictResolverMode.values()) System.out.println(c);
public static GridDrReceiverCacheConflictResolverMode valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant
with the specified nameNullPointerException - if the argument is null@Nullable public static GridDrReceiverCacheConflictResolverMode fromOrdinal(int ord)
ord - Ordinal value.null if ordinal out of range.Copyright © 2014. All rights reserved.