org.apache.zookeeper.server.upgrade
Class UpgradeSnapShotV1
java.lang.Object
org.apache.zookeeper.server.upgrade.UpgradeSnapShotV1
- All Implemented Interfaces:
- UpgradeSnapShot
public class UpgradeSnapShotV1
- extends java.lang.Object
- implements UpgradeSnapShot
This class gets the old snapshot
and the old dataDir and creates
an brand new snapshot that is
then converted to the new snapshot
for upgrading.
Constructor Summary |
UpgradeSnapShotV1(java.io.File dataDir,
java.io.File snapShotDir)
upgrade from version 1 to version 2 |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
UpgradeSnapShotV1
public UpgradeSnapShotV1(java.io.File dataDir,
java.io.File snapShotDir)
- upgrade from version 1 to version 2
- Parameters:
dataDir
- snapShotDir
-
playLog
public long playLog(org.apache.jute.InputArchive logStream)
throws java.io.IOException
- play the log from this logstream into the datatree
- Parameters:
logStream
-
- Returns:
-
- Throws:
java.io.IOException
getNewDataTree
public DataTree getNewDataTree()
throws java.io.IOException
- Specified by:
getNewDataTree
in interface UpgradeSnapShot
- Throws:
java.io.IOException
getSessionWithTimeOuts
public java.util.concurrent.ConcurrentHashMap<java.lang.Long,java.lang.Integer> getSessionWithTimeOuts()
- Specified by:
getSessionWithTimeOuts
in interface UpgradeSnapShot
Copyright © 2012 The Apache Software Foundation