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
Constructors Constructor Description UpgradeSnapShotV1(java.io.File dataDir, java.io.File snapShotDir)
upgrade from version 1 to version 2
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description DataTree
getNewDataTree()
java.util.concurrent.ConcurrentHashMap<java.lang.Long,java.lang.Integer>
getSessionWithTimeOuts()
long
playLog(org.apache.jute.InputArchive logStream)
play the log from this logstream into the datatree
-
-
-
Method Detail
-
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 interfaceUpgradeSnapShot
- Throws:
java.io.IOException
-
getSessionWithTimeOuts
public java.util.concurrent.ConcurrentHashMap<java.lang.Long,java.lang.Integer> getSessionWithTimeOuts()
- Specified by:
getSessionWithTimeOuts
in interfaceUpgradeSnapShot
-
-