public class MapReplicationUpdate extends Object implements InternalWanReplicationEvent, IdentifiedDataSerializable
Constructor and Description |
---|
MapReplicationUpdate() |
MapReplicationUpdate(String mapName,
SplitBrainMergePolicy mergePolicy,
EntryView<Data,Data> entryView) |
Modifier and Type | Method and Description |
---|---|
int |
getBackupCount()
Returns the backup count (sync and async) for this WAN event.
|
int |
getClassId()
Returns type identifier for this class.
|
Set<String> |
getClusterNames()
Returns the set of cluster names on which this event has already
been processed.
|
long |
getCreationTime()
Returns the creation time for this event in milliseconds.
|
WanMapEntryView<Data,Data> |
getEntryView() |
int |
getFactoryId()
Returns DataSerializableFactory factory ID for this class.
|
Data |
getKey()
Returns the key for the entry on which the event occurred.
|
SplitBrainMergePolicy |
getMergePolicy() |
String |
getObjectName()
Returns the name of the distributed object (map or cache) on which this
event occurred.
|
String |
getServiceName()
Returns the service name on which this event occurred.
|
void |
incrementEventCount(DistributedServiceWanEventCounters counters)
Increments the count for the related event in the
counters |
void |
readData(ObjectDataInput in)
Reads fields from the input stream
|
void |
setEntryView(WanMapEntryView<Data,Data> entryView) |
void |
setMergePolicy(SplitBrainMergePolicy mergePolicy) |
void |
writeData(ObjectDataOutput out)
Writes object fields to output stream
|
public MapReplicationUpdate()
public MapReplicationUpdate(String mapName, SplitBrainMergePolicy mergePolicy, EntryView<Data,Data> entryView)
public SplitBrainMergePolicy getMergePolicy()
public void setMergePolicy(SplitBrainMergePolicy mergePolicy)
public WanMapEntryView<Data,Data> getEntryView()
public void setEntryView(WanMapEntryView<Data,Data> entryView)
public void writeData(ObjectDataOutput out) throws IOException
DataSerializable
writeData
in interface DataSerializable
out
- outputIOException
- if an I/O error occurs. In particular,
an IOException
may be thrown if the
output stream has been closed.public void readData(ObjectDataInput in) throws IOException
DataSerializable
readData
in interface DataSerializable
in
- inputIOException
- if an I/O error occurs. In particular,
an IOException
may be thrown if the
input stream has been closed.public int getFactoryId()
IdentifiedDataSerializable
getFactoryId
in interface IdentifiedDataSerializable
public int getClassId()
IdentifiedDataSerializable
getClassId
in interface IdentifiedDataSerializable
public void incrementEventCount(DistributedServiceWanEventCounters counters)
WanReplicationEvent
counters
incrementEventCount
in interface WanReplicationEvent
counters
- the WAN event counter@Nonnull public Data getKey()
InternalWanReplicationEvent
getKey
in interface InternalWanReplicationEvent
@Nonnull public Set<String> getClusterNames()
InternalWanReplicationEvent
getClusterNames
in interface InternalWanReplicationEvent
public int getBackupCount()
InternalWanReplicationEvent
getBackupCount
in interface InternalWanReplicationEvent
public long getCreationTime()
InternalWanReplicationEvent
getCreationTime
in interface InternalWanReplicationEvent
Clock.currentTimeMillis()
public String getServiceName()
WanReplicationEvent
getServiceName
in interface WanReplicationEvent
public String getObjectName()
WanReplicationEvent
getObjectName
in interface WanReplicationEvent
Copyright © 2019 Hazelcast, Inc.. All rights reserved.