jonvex commented on code in PR #9553:
URL: https://github.com/apache/hudi/pull/9553#discussion_r1307614341
##########
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/metadata/HoodieBackedTableMetadataWriter.java:
##########
@@ -1023,14 +1023,19 @@ public void update(HoodieRollbackMetadata
rollbackMetadata, String instantTime)
validateRollback(commitToRollbackInstantTime, compactionInstant,
deltacommitsSinceCompaction);
- // lets apply a delta commit with DT's rb instant(with special suffix)
containing following records:
+ // lets apply a delta commit with DT's rb instant containing following
records:
// a. any log files as part of RB commit metadata that was added
// b. log files added by the commit in DT being rolled back. By rolled
back, we mean, a rollback block will be added and does not mean it will be
deleted.
// both above list should only be added to FILES partition.
-
- String rollbackInstantTime = createRollbackTimestamp(instantTime);
+ if (deltacommitsSinceCompaction.containsInstant(instantTime)) {
+ LOG.info("Rolling back MDT deltacommit for " + instantTime + ", since
previous attempt failed");
+ if (!getWriteClient().rollback(instantTime)) {
Review Comment:
If the first rollback fails, we need to attempt the rollback again. If it
failed after the MDT write, then we need to rollback the changes that the first
rollback did to the MDT
--
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]