flink-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From GitBox <...@apache.org>
Subject [GitHub] [flink] lirui-apache commented on a change in pull request #10062: [FLINK-14588][hive] Support Hive version 1.0.0 and 1.0.1
Date Fri, 01 Nov 2019 02:41:41 GMT
lirui-apache 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_r341433876
 
 

 ##########
 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:
   I have checked and what's missing is not really needed.

----------------------------------------------------------------
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:
users@infra.apache.org


With regards,
Apache Git Services

Mime
View raw message