Package org.apache.accumulo.server
Class AccumuloDataVersion
- java.lang.Object
-
- org.apache.accumulo.server.AccumuloDataVersion
-
public class AccumuloDataVersion extends Object
Class representing the version of data stored in Accumulo.This version is separate but related to the file specific version in
RFile. A version change to RFile will reflect a version change to the AccumuloDataVersion. But a version change to the AccumuloDataVersion may not affect the version number in RFile. For example, changes made to other parts of Accumulo that affects how data is stored, like the metadata table, would change the AccumuloDataVersion number here but not in RFile.This number is stored in HDFS under
Constants.VERSION_DIR.This class is used for checking the version during server startup and upgrades.
-
-
Field Summary
Fields Modifier and Type Field Description static Set<Integer>CAN_RUNstatic intREMOVE_DEPRECATIONS_FOR_VERSION_3version (11) reflects removal of replication starting with 3.0static intROOT_TABLET_META_CHANGESversion (10) reflects changes to how root tablet metadata is serialized in zookeeper starting with 2.1.
-
Constructor Summary
Constructors Constructor Description AccumuloDataVersion()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static intget()Get the current Accumulo Data Version.static intgetCurrentVersion(ServerContext context)Get the stored, current working version.static StringoldestUpgradeableVersionName()
-
-
-
Field Detail
-
REMOVE_DEPRECATIONS_FOR_VERSION_3
public static final int REMOVE_DEPRECATIONS_FOR_VERSION_3
version (11) reflects removal of replication starting with 3.0- See Also:
- Constant Field Values
-
ROOT_TABLET_META_CHANGES
public static final int ROOT_TABLET_META_CHANGES
version (10) reflects changes to how root tablet metadata is serialized in zookeeper starting with 2.1. SeeRootTabletMetadata.- See Also:
- Constant Field Values
-
-
Method Detail
-
get
public static int get()
Get the current Accumulo Data Version. See Javadoc of static final integers for a detailed description of that version.- Returns:
- integer representing the Accumulo Data Version
-
getCurrentVersion
public static int getCurrentVersion(ServerContext context)
Get the stored, current working version.- Parameters:
context- the server context- Returns:
- the stored data version
-
oldestUpgradeableVersionName
public static String oldestUpgradeableVersionName()
-
-