alexeykudinkin commented on a change in pull request #4753:
URL: https://github.com/apache/hudi/pull/4753#discussion_r803061314
##########
File path:
hudi-client/hudi-flink-client/src/main/java/org/apache/hudi/client/HoodieFlinkWriteClient.java
##########
@@ -391,16 +387,11 @@ public void completeCompaction(
}
@Override
- protected List<WriteStatus> compact(String compactionInstantTime, boolean
shouldComplete) {
+ protected HoodieWriteMetadata<List<WriteStatus>> compact(String
compactionInstantTime, boolean shouldComplete) {
// only used for metadata table, the compaction happens in single thread
- try {
- List<WriteStatus> writeStatuses =
- getHoodieTable().compact(context,
compactionInstantTime).getWriteStatuses();
- commitCompaction(compactionInstantTime, writeStatuses, Option.empty());
- return writeStatuses;
- } catch (IOException e) {
- throw new HoodieException("Error while compacting instant: " +
compactionInstantTime);
- }
+ HoodieWriteMetadata<List<WriteStatus>> compactionMetadata =
getHoodieTable().compact(context, compactionInstantTime);
+ commitCompaction(compactionInstantTime,
compactionMetadata.getCommitMetadata().get(), Option.empty());
Review comment:
Gotcha. Yeah, we should streamline this data-flow to make it more
transparent (no need to change it in your PR though)
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]