public class ShardedExportToCloudStorage extends AbstractExportToCloudStorage
| Modifier and Type | Field and Description |
|---|---|
static long |
APPROXIMATE_EXPORT_FILE_SIZE |
static int |
APPROXIMATE_MAX_EXPORT_FILES |
static int |
MAX_EXPORT_SHARDS_DEFAULT |
static java.lang.String |
MAX_EXPORT_SHARDS_KEY |
static int |
MIN_SHARDS_FOR_SHARDED_EXPORT |
static int |
NUM_MAP_TASKS_HINT_DEFAULT |
static java.lang.String |
NUM_MAP_TASKS_HINT_KEY |
bigQueryHelper, configuration, DESTINATION_FORMAT_KEY, exportJobReference, fileFormat, gcsPath, projectId, tableToExport| Constructor and Description |
|---|
ShardedExportToCloudStorage(org.apache.hadoop.conf.Configuration configuration,
java.lang.String gcsPath,
ExportFileFormat fileFormat,
BigQueryHelper bigQueryHelper,
java.lang.String projectId,
com.google.api.services.bigquery.model.Table tableToExport) |
| Modifier and Type | Method and Description |
|---|---|
java.util.List<java.lang.String> |
getExportPaths()
Get a list of export paths to provide to BigQuery
|
java.util.List<org.apache.hadoop.mapreduce.InputSplit> |
getSplits(org.apache.hadoop.mapreduce.JobContext context)
Get input splits that should be passed to Hadoop.
|
void |
waitForUsableMapReduceInput()
Wait for enough data to be available for us to start a MapReduce.
|
beginExport, cleanupExport, preparepublic static final java.lang.String NUM_MAP_TASKS_HINT_KEY
public static final int NUM_MAP_TASKS_HINT_DEFAULT
public static final java.lang.String MAX_EXPORT_SHARDS_KEY
public static final int MAX_EXPORT_SHARDS_DEFAULT
public static final long APPROXIMATE_EXPORT_FILE_SIZE
public static final int APPROXIMATE_MAX_EXPORT_FILES
public static final int MIN_SHARDS_FOR_SHARDED_EXPORT
public ShardedExportToCloudStorage(org.apache.hadoop.conf.Configuration configuration,
java.lang.String gcsPath,
ExportFileFormat fileFormat,
BigQueryHelper bigQueryHelper,
java.lang.String projectId,
com.google.api.services.bigquery.model.Table tableToExport)
throws java.io.IOException
java.io.IOExceptionpublic void waitForUsableMapReduceInput()
throws java.io.IOException,
java.lang.InterruptedException
Exportjava.io.IOExceptionjava.lang.InterruptedExceptionpublic java.util.List<org.apache.hadoop.mapreduce.InputSplit> getSplits(org.apache.hadoop.mapreduce.JobContext context)
throws java.io.IOException
Exportjava.io.IOExceptionpublic java.util.List<java.lang.String> getExportPaths()
throws java.io.IOException
Exportjava.io.IOExceptionCopyright © 2019. All rights reserved.