rich7420 commented on code in PR #11135:
URL: https://github.com/apache/ozone/pull/11135#discussion_r3886128283
##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/s3/multipart/S3MultipartUploadCompleteRequest.java:
##########
@@ -341,6 +341,11 @@ public OMClientResponse
validateAndUpdateCache(OzoneManager ozoneManager, Execut
if (keyToDelete != null && !omBucketInfo.getIsVersionEnabled()) {
RepeatedOmKeyInfo oldKeyVersionsToDelete = getOldVersionsToCleanUp(
keyToDelete, omBucketInfo.getObjectID(), trxnLogIndex);
+ // Remove any block from oldKeyVersionsToDelete that shares the same
+ // container ID and local ID with omKeyInfo blocks'.
+ // Otherwise, it causes data loss once those shared blocks are added
+ // to deletedTable and processed by KeyDeletingService for deletion.
+ filterOutBlocksStillInUse(omKeyInfo, oldKeyVersionsToDelete);
Review Comment:
nit: could add a line on why the `Pair` return is ignored here, since
`OMKeyCommitRequest` uses it for quota. MPU already counts the bytes at
commit-part.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]