xuefuz commented on a change in pull request #10062: [FLINK-14588][hive]
Support Hive version 1.0.0 and 1.0.1
URL: https://github.com/apache/flink/pull/10062#discussion_r341272803
##########
File path:
flink-connectors/flink-connector-hive/src/main/java/org/apache/flink/connectors/hive/HiveTableOutputFormat.java
##########
@@ -441,17 +444,6 @@ public void close() throws IOException {
private HivePartitionWriter writerForLocation(String location) throws
IOException {
JobConf clonedConf = new JobConf(jobConf);
clonedConf.set(OUTDIR, location);
- OutputFormat outputFormat;
- try {
- StorageDescriptor sd =
hiveTablePartition.getStorageDescriptor();
- Class outputFormatClz =
Class.forName(sd.getOutputFormat(), true,
- Thread.currentThread().getContextClassLoader());
- outputFormatClz =
HiveFileFormatUtils.getOutputFormatSubstitute(outputFormatClz);
- outputFormat = (OutputFormat)
outputFormatClz.newInstance();
- } catch (InstantiationException | IllegalAccessException |
ClassNotFoundException e) {
- throw new FlinkRuntimeException("Unable to instantiate
the hadoop output format", e);
- }
- ReflectionUtils.setConf(outputFormat, clonedConf);
Review comment:
Do we miss anything by removing this part of code?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services