fix(core): use correct clustering action for 0.x vs 1.x in BaseHoodieTableServiceClient#18942
fix(core): use correct clustering action for 0.x vs 1.x in BaseHoodieTableServiceClient#18942rahil-c wants to merge 1 commit into
Conversation
…TableServiceClient
hudi-agent
left a comment
There was a problem hiding this comment.
🤖 This review was generated by an AI agent and may contain mistakes. Please verify any suggestions before applying.
Thanks for the fix! This correctly switches completeClustering in both the base and Flink table service clients to use the actual action from the clustering instant (so metrics land under clustering.* for 1.x tables and replacecommit.* for legacy 0.x tables) instead of always hardcoding CLUSTERING_ACTION. clusteringInstant is resolved earlier in each method with .get(), so it's safe to read its action here, and the new test covers both action paths. No issues flagged from this automated pass — a Hudi committer or PMC member can take it from here for a final review.
cc @yihua
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #18942 +/- ##
=========================================
Coverage 68.20% 68.20%
Complexity 29458 29458
=========================================
Files 2542 2542
Lines 142545 142546 +1
Branches 17778 17778
=========================================
+ Hits 97218 97226 +8
+ Misses 37316 37310 -6
+ Partials 8011 8010 -1
Flags with carried forward coverage won't be shown. Click here to find out more.
🚀 New features to boost your workflow:
|
| long durationInMs = metrics.getDurationInMs(clusteringTimer.stop()); | ||
| TimelineUtils.parseDateFromInstantTimeSafely(clusteringCommitTime).ifPresent(parsedInstant -> | ||
| metrics.updateCommitMetrics(parsedInstant.getTime(), durationInMs, replaceCommitMetadata, HoodieActiveTimeline.CLUSTERING_ACTION) | ||
| metrics.updateCommitMetrics(parsedInstant.getTime(), durationInMs, replaceCommitMetadata, clusteringInstant.getAction()) |
There was a problem hiding this comment.
we need to hard code this to "replacecommit".
…TableServiceClient
Describe the issue this Pull Request addresses
Summary and Changelog
Impact
Risk Level
Documentation Update
Contributor's checklist