lirui-apache commented on a change in pull request #9067: [FLINK-13069][hive]
HiveTableSink should implement OverwritableTableSink
URL: https://github.com/apache/flink/pull/9067#discussion_r302348621
##########
File path:
flink-connectors/flink-connector-hive/src/main/java/org/apache/flink/batch/connectors/hive/HiveTableOutputFormat.java
##########
@@ -198,6 +199,7 @@ private void readObject(ObjectInputStream in) throws
IOException, ClassNotFoundE
tablePath = (ObjectPath) in.readObject();
partitionToWriter = new HashMap<>();
tableProperties = (Properties) in.readObject();
+ hiveVersion =
jobConf.get(HiveCatalogValidator.CATALOG_HIVE_VERSION,
HiveShimLoader.getHiveVersion());
Review comment:
`open` is called on TM but not on JM, where `finalizeGlobal` is performed.
That's why I initialize hiveVersion in `readObject` and constructor (to be
safe).
I'll serialize this field instead of getting it from jobConf.
----------------------------------------------------------------
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