use of com.hazelcast.map.impl.record.RecordInfo in project hazelcast by hazelcast.
the class MergeOperation method getBackupOperation.
@Override
public Operation getBackupOperation() {
if (dataValue == null) {
return new RemoveBackupOperation(name, dataKey, false, disableWanReplicationEvent);
} else {
final Record record = recordStore.getRecord(dataKey);
final RecordInfo replicationInfo = Records.buildRecordInfo(record);
return new PutBackupOperation(name, dataKey, dataValue, replicationInfo, false, false, disableWanReplicationEvent);
}
}
use of com.hazelcast.map.impl.record.RecordInfo in project hazelcast by hazelcast.
the class PutAllOperation method put.
private void put(Data dataKey, Data dataValue) {
Object oldValue = putToRecordStore(dataKey, dataValue);
dataValue = getValueOrPostProcessedValue(dataKey, dataValue);
mapServiceContext.interceptAfterPut(name, dataValue);
if (hasMapListener) {
EntryEventType eventType = (oldValue == null ? ADDED : UPDATED);
mapEventPublisher.publishEvent(getCallerAddress(), name, eventType, dataKey, oldValue, dataValue);
}
Record record = (hasWanReplication || hasBackups) ? recordStore.getRecord(dataKey) : null;
if (hasWanReplication) {
EntryView entryView = createSimpleEntryView(dataKey, dataValue, record);
mapEventPublisher.publishWanReplicationUpdate(name, entryView);
}
if (hasBackups) {
RecordInfo replicationInfo = buildRecordInfo(record);
backupRecordInfos.add(replicationInfo);
}
evict(dataKey);
if (hasInvalidation) {
invalidationKeys.add(dataKey);
}
}
use of com.hazelcast.map.impl.record.RecordInfo in project hazelcast by hazelcast.
the class TxnSetOperation method getBackupOperation.
public Operation getBackupOperation() {
final Record record = recordStore.getRecord(dataKey);
final RecordInfo replicationInfo = record != null ? Records.buildRecordInfo(record) : null;
return new PutBackupOperation(name, dataKey, dataValue, replicationInfo, true, false);
}
Aggregations