public class StandaloneHiveServerContext extends Object implements HiveServerContext
This class contains a bunch of methods meant to be overridden in order to create slightly different contexts.
This context configures HiveServer for both mr and tez. There's nothing contradicting with those configurations so they may coexist in order to allow test cases to alter execution engines within the same test by e.g: 'set hive.execution.engine=tez;'.
| Modifier and Type | Field and Description |
|---|---|
protected org.apache.hadoop.hive.conf.HiveConf |
hiveConf |
| Constructor and Description |
|---|
StandaloneHiveServerContext(Path basedir,
HiveRunnerConfig hiveRunnerConfig) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
configureAssertionStatus(org.apache.hadoop.hive.conf.HiveConf conf) |
protected void |
configureFileSystem(Path basedir,
org.apache.hadoop.hive.conf.HiveConf conf) |
protected void |
configureJavaSecurityRealm(org.apache.hadoop.hive.conf.HiveConf hiveConf) |
protected void |
configureMetaStore(org.apache.hadoop.hive.conf.HiveConf conf) |
protected void |
configureMiscHiveSettings(org.apache.hadoop.hive.conf.HiveConf hiveConf) |
protected void |
configureMrExecutionEngine(org.apache.hadoop.hive.conf.HiveConf conf) |
protected void |
configureSupportConcurrency(org.apache.hadoop.hive.conf.HiveConf conf) |
protected void |
configureTezExecutionEngine(org.apache.hadoop.hive.conf.HiveConf conf) |
protected void |
createAndSetFolderProperty(org.apache.hadoop.hive.conf.HiveConf.ConfVars var,
String folder,
org.apache.hadoop.hive.conf.HiveConf conf,
Path basedir) |
protected void |
createAndSetFolderProperty(String key,
String folder,
org.apache.hadoop.hive.conf.HiveConf conf,
Path basedir) |
Path |
getBaseDir()
Get file folder that acts as the base dir for the test data.
|
org.apache.hadoop.hive.conf.HiveConf |
getHiveConf()
Get the hiveconf.
|
void |
init()
Create all test resources and set all hive configurations.
|
protected void |
overrideHiveConf(org.apache.hadoop.hive.conf.HiveConf hiveConf) |
protected void |
setMetastoreProperty(String key,
String value) |
public StandaloneHiveServerContext(Path basedir, HiveRunnerConfig hiveRunnerConfig)
public final void init()
HiveServerContextHiveServerContainer.init(Map, Map)init in interface HiveServerContextprotected void configureMiscHiveSettings(org.apache.hadoop.hive.conf.HiveConf hiveConf)
protected void overrideHiveConf(org.apache.hadoop.hive.conf.HiveConf hiveConf)
protected void configureMrExecutionEngine(org.apache.hadoop.hive.conf.HiveConf conf)
protected void configureTezExecutionEngine(org.apache.hadoop.hive.conf.HiveConf conf)
protected void configureJavaSecurityRealm(org.apache.hadoop.hive.conf.HiveConf hiveConf)
protected void configureAssertionStatus(org.apache.hadoop.hive.conf.HiveConf conf)
protected void configureSupportConcurrency(org.apache.hadoop.hive.conf.HiveConf conf)
protected void configureMetaStore(org.apache.hadoop.hive.conf.HiveConf conf)
protected void configureFileSystem(Path basedir, org.apache.hadoop.hive.conf.HiveConf conf) throws IOException
IOExceptionpublic org.apache.hadoop.hive.conf.HiveConf getHiveConf()
HiveServerContextgetHiveConf in interface HiveServerContextpublic Path getBaseDir()
HiveServerContextEach test method will have a new base dir spawned by the HiveRunner engine.
getBaseDir in interface HiveServerContextprotected final void createAndSetFolderProperty(org.apache.hadoop.hive.conf.HiveConf.ConfVars var,
String folder,
org.apache.hadoop.hive.conf.HiveConf conf,
Path basedir)
throws IOException
IOExceptionprotected final void createAndSetFolderProperty(String key, String folder, org.apache.hadoop.hive.conf.HiveConf conf, Path basedir) throws IOException
IOExceptionCopyright © 2013–2020. All rights reserved.