org.apache.hadoop.hive.metastore
Class MetaStoreSchemaInfo

java.lang.Object
  extended by org.apache.hadoop.hive.metastore.MetaStoreSchemaInfo

public class MetaStoreSchemaInfo
extends Object


Constructor Summary
MetaStoreSchemaInfo(String hiveHome, HiveConf hiveConf, String dbType)
           
 
Method Summary
 String generateInitFileName(String toVersion)
          Get the name of the script to initialize the schema for given version
static String getHiveSchemaVersion()
           
 String getMetaStoreScriptDir()
          Find the directory of metastore scripts
 List<String> getUpgradeScripts(String fromVersion)
          Get the list of sql scripts required to upgrade from the give version to current
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

MetaStoreSchemaInfo

public MetaStoreSchemaInfo(String hiveHome,
                           HiveConf hiveConf,
                           String dbType)
                    throws HiveMetaException
Throws:
HiveMetaException
Method Detail

getUpgradeScripts

public List<String> getUpgradeScripts(String fromVersion)
                               throws HiveMetaException
Get the list of sql scripts required to upgrade from the give version to current

Parameters:
fromVersion -
Returns:
Throws:
HiveMetaException

generateInitFileName

public String generateInitFileName(String toVersion)
                            throws HiveMetaException
Get the name of the script to initialize the schema for given version

Parameters:
toVersion - Target version. If it's null, then the current server version is used
Returns:
Throws:
HiveMetaException

getMetaStoreScriptDir

public String getMetaStoreScriptDir()
Find the directory of metastore scripts

Returns:

getHiveSchemaVersion

public static String getHiveSchemaVersion()


Copyright © 2012 The Apache Software Foundation