try {
String storeName = request.getStoreName();
IStorageEngine<ByteArray, byte[]> store =
syncManager.getRawStore(storeName);
ByteArray key = new ByteArray(request.getKey());
VectorClock newclock;
if (request.isSetVersion()) {
newclock = TProtocolUtil.getVersion(request.getVersion());
} else {
newclock = new VectorClock();
List<IVersion> versions = store.getVersions(key);
for (IVersion v : versions) {
newclock = newclock.merge((VectorClock)v);
}
}
newclock =
newclock.incremented(rpcService.syncManager.getLocalNodeId(),
System.currentTimeMillis());
Versioned<byte[]> value = Versioned.value(null, newclock);
store.put(key, value);
DeleteResponseMessage m = new DeleteResponseMessage();