voldemort.client.scheduler
Class AsyncMetadataVersionManager
java.lang.Object
voldemort.client.scheduler.AsyncMetadataVersionManager
- All Implemented Interfaces:
- java.lang.Runnable
public class AsyncMetadataVersionManager
- extends java.lang.Object
- implements java.lang.Runnable
The AsyncMetadataVersionManager is used to track the Metadata version on the
cluster and if necessary Re-bootstrap the client.
During initialization, it will retrieve the current version of the
cluster.xml and then periodically check whether this has been updated. During
init if the initial version turns out to be null, it means that no change has
been done to that store since it was created. In this case, we assume version
'0'.
- Author:
- csoman
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
isActive
public boolean isActive
AsyncMetadataVersionManager
public AsyncMetadataVersionManager(SystemStoreRepository sysRepository,
java.util.concurrent.Callable<java.lang.Void> storeClientThunk,
java.lang.String storeName)
getCurrentVersion
public java.lang.Long getCurrentVersion(java.lang.String versionKey,
java.util.Properties versionProps)
fetchNewVersion
public java.lang.Long fetchNewVersion(java.lang.String versionKey,
java.lang.Long curVersion,
java.util.Properties versionProps)
run
public void run()
- Specified by:
run
in interface java.lang.Runnable
getClusterMetadataVersion
public java.lang.Long getClusterMetadataVersion()
getStoreMetadataVersion
public java.lang.Long getStoreMetadataVersion()
updateMetadataVersions
public void updateMetadataVersions()
Jay Kreps, Roshan Sumbaly, Alex Feinberg, Bhupesh Bansal, Lei Gao, Chinmay Soman, Vinoth Chandar, Zhongjie Wu