public static final List<MapWritable> mapperData2 = ImmutableList.of(row3, row4);
private HiveTools() {}
public static void setupJob(Configuration conf) throws IOException {
HiveOutputDescription outputDesc = new HiveOutputDescription();
outputDesc.setDbName("default");
outputDesc.setTableName("hive_io_test");
Map<String, String> partitionValues = ImmutableMap.of("ds", "2013-04-01");
outputDesc.setPartitionValues(partitionValues);
LOG.info("Writing to {}", outputDesc);
try {
HiveApiOutputFormat.initProfile(conf, outputDesc, SampleOutputFormat.SAMPLE_PROFILE_ID);
} catch (TException e) {
LOG.error("Failed to initialize profile {}", outputDesc);