public class IntegrationTestSparkBulkLoad extends IntegrationTestBase
IntegrationTestBulkLoad in mapreduce.
Usage on cluster:
First add hbase related jars and hbase-spark.jar into spark classpath.
spark-submit --class org.apache.hadoop.hbase.spark.IntegrationTestSparkBulkLoad
HBASE_HOME/lib/hbase-spark-it-XXX-tests.jar -m slowDeterministic -Dhbase.spark.bulkload.chainlength=300| Modifier and Type | Class and Description |
|---|---|
static class |
IntegrationTestSparkBulkLoad.createCombinerFunc |
static class |
IntegrationTestSparkBulkLoad.LinkedListCheckingFlatMapFunc
PairFlatMapFunction used to transfer
|
static class |
IntegrationTestSparkBulkLoad.LinkedListCheckingForeachFunc
Sort all LinkChain for one LinkKey, and test List
|
static class |
IntegrationTestSparkBulkLoad.LinkedListCreationMapper |
static class |
IntegrationTestSparkBulkLoad.ListToKeyValueFunc |
static class |
IntegrationTestSparkBulkLoad.mergeCombinersFunc |
static class |
IntegrationTestSparkBulkLoad.mergeValueFunc |
static class |
IntegrationTestSparkBulkLoad.NaturalKeyPartitioner
Class to figure out what partition to send a link in the chain to.
|
static class |
IntegrationTestSparkBulkLoad.SparkLinkChain
Writable used as the value emitted from a pass over the hbase table.
|
static class |
IntegrationTestSparkBulkLoad.SparkLinkKey
Writable class used as the key to group links in the linked list.
|
CHAOS_MONKEY_PROPS, monkey, MONKEY_LONG_OPT, monkeyProps, monkeyToUse, NO_CLUSTER_CLEANUP_LONG_OPT, noClusterCleanUp, utilcmdLineArgs, conf, EXIT_FAILURE, EXIT_SUCCESS, LONG_HELP_OPTION, options, SHORT_HELP_OPTION| Constructor and Description |
|---|
IntegrationTestSparkBulkLoad() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
addOptions() |
protected Set<String> |
getColumnFamilies()
Provides the name of the CFs that are protected from random Chaos monkey activity (alter)
|
TableName |
getTablename()
Provides the name of the table that is protected from random Chaos monkey activity
|
static TableName |
getTableName(org.apache.hadoop.conf.Configuration conf) |
static void |
main(String[] args) |
protected void |
processOptions(org.apache.hbase.thirdparty.org.apache.commons.cli.CommandLine cmd) |
void |
runCheck()
After adding data to the table start a mr job to
|
void |
runLinkedListSparkJob(int iteration)
Running spark job to create LinkedList for testing
|
void |
runLoad()
Running spark job to load data into hbase table
|
int |
runTestFromCommandLine() |
void |
setUpCluster() |
void |
testBulkLoad() |
cleanUp, cleanUpCluster, cleanUpMonkey, cleanUpMonkey, doWork, getConf, getDefaultMonkeyFactory, getTestingUtil, processBaseOptions, setUp, setUpMonkey, startMonkeyaddOption, addOptNoArg, addOptNoArg, addOptWithArg, addOptWithArg, addRequiredOption, addRequiredOptWithArg, addRequiredOptWithArg, doStaticMain, getOptionAsDouble, getOptionAsInt, getOptionAsLong, newParser, parseArgs, parseInt, parseLong, printUsage, printUsage, processOldArgs, run, setConfpublic IntegrationTestSparkBulkLoad()
public void runLoad() throws Exception
Exceptionpublic void runLinkedListSparkJob(int iteration) throws Exception
iteration - iteration th of this jobExceptionpublic void testBulkLoad() throws Exception
Exceptionpublic void setUpCluster() throws Exception
setUpCluster in class IntegrationTestBaseExceptionprotected void addOptions()
addOptions in class IntegrationTestBaseprotected void processOptions(org.apache.hbase.thirdparty.org.apache.commons.cli.CommandLine cmd)
processOptions in class IntegrationTestBasepublic int runTestFromCommandLine() throws Exception
runTestFromCommandLine in class IntegrationTestBaseExceptionpublic TableName getTablename()
IntegrationTestBasegetTablename in class IntegrationTestBasepublic static TableName getTableName(org.apache.hadoop.conf.Configuration conf)
protected Set<String> getColumnFamilies()
IntegrationTestBasegetColumnFamilies in class IntegrationTestBaseCopyright © 2007–2019 Cloudera. All rights reserved.