voldemort.server.protocol.admin
Class TimeBasedUpdatePartitionEntriesStreamRequestHandler
java.lang.Object
voldemort.server.protocol.admin.UpdatePartitionEntriesStreamRequestHandler
voldemort.server.protocol.admin.TimeBasedUpdatePartitionEntriesStreamRequestHandler
- All Implemented Interfaces:
- StreamRequestHandler
public class TimeBasedUpdatePartitionEntriesStreamRequestHandler
- extends UpdatePartitionEntriesStreamRequestHandler
This class implements a streaming interface into a voldemort server, that
resolves based on timestamp.
Specifically, the policy implemented is "overwrite if later". That is, if
(and only if), the streamed in version's timestamp is greater than the
timestamps of ALL" versions on storage, the key is overwritten atomically
with the streamed version. Else, the key is unmodified.
NOTE: This class does not do any buffering like
BufferedUpdatePartitionEntriesStreamRequestHandler
since this is
mainly intended to be used for streaming values in from external sources.
Fields inherited from class voldemort.server.protocol.admin.UpdatePartitionEntriesStreamRequestHandler |
counter, errorCodeMapper, filter, isBatchWriteOff, logger, request, responseBuilder, startTime, storageEngine, streamStats, throttler |
Methods inherited from class java.lang.Object |
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TimeBasedUpdatePartitionEntriesStreamRequestHandler
public TimeBasedUpdatePartitionEntriesStreamRequestHandler(VAdminProto.UpdatePartitionEntriesRequest request,
ErrorCodeMapper errorCodeMapper,
VoldemortConfig voldemortConfig,
StorageEngine<ByteArray,byte[],byte[]> storageEngine,
StoreRepository storeRepository,
NetworkClassLoader networkClassLoader)
processEntry
protected void processEntry(ByteArray key,
Versioned<byte[]> value)
throws java.io.IOException
- Overrides:
processEntry
in class UpdatePartitionEntriesStreamRequestHandler
- Throws:
java.io.IOException
getHandlerName
protected java.lang.String getHandlerName()
- Overrides:
getHandlerName
in class UpdatePartitionEntriesStreamRequestHandler
Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao, Chinmay Soman, Vinoth Chandar, Zhongjie Wu