Store
- store of a partitionpublic abstract class AbstractSplitBrainHandlerService<Store> extends Object implements SplitBrainHandlerService
Modifier | Constructor and Description |
---|---|
protected |
AbstractSplitBrainHandlerService(NodeEngine nodeEngine) |
Modifier and Type | Method and Description |
---|---|
protected abstract void |
destroyStore(Store store)
Destroys the given
Store . |
protected abstract boolean |
hasEntries(Store store)
Checks if the given
Store has entries. |
protected abstract boolean |
hasMergeablePolicy(Store store)
Checks if the given
Store has a mergeable merge policy. |
protected abstract Runnable |
newMergeRunnable(Collection<Store> mergingStores)
Returns a runnable which merges the given
Store instances. |
protected void |
onStoreCollection(Store store)
Final cleanup before starting merge after
StoreCollector
collects a store. |
Runnable |
prepareMergeRunnable()
When the two separate clusters merge (resolve a split-brain), this method is called to return
a
Runnable , that will merge the clusters. |
protected abstract Iterator<Store> |
storeIterator(int partitionId)
Returns an
Iterator over all Store instances in the given partition. |
protected AbstractSplitBrainHandlerService(NodeEngine nodeEngine)
public final Runnable prepareMergeRunnable()
SplitBrainHandlerService
Runnable
, that will merge the clusters.prepareMergeRunnable
in interface SplitBrainHandlerService
Runnable
that will merge the clustersprotected void onStoreCollection(Store store)
StoreCollector
collects a store. If we do this cleanup upon join of merging node,
concurrently running merge and migration operations can cause
inconsistency over shared data. For example, dropping of map
indexes is done at this stage not to lose index data.protected abstract Runnable newMergeRunnable(Collection<Store> mergingStores)
Store
instances.protected abstract Iterator<Store> storeIterator(int partitionId)
Iterator
over all Store
instances in the given partition.protected abstract void destroyStore(Store store)
Store
.protected abstract boolean hasEntries(Store store)
Store
has entries.true
if the store has entries, false
otherwiseprotected abstract boolean hasMergeablePolicy(Store store)
Store
has a mergeable merge policy.true
if the store has a mergeable merge policy, false
otherwiseCopyright © 2020 Hazelcast, Inc.. All Rights Reserved.