sumitagrawl commented on code in PR #5167:
URL: https://github.com/apache/ozone/pull/5167#discussion_r1290058724


##########
hadoop-ozone/common/src/main/java/org/apache/hadoop/ozone/om/helpers/OmKeyInfo.java:
##########
@@ -425,6 +425,25 @@ public FileChecksum getFileChecksum() {
     return fileChecksum;
   }
 
+  @Override
+  public String toString() {
+    return "OmKeyInfo{" +
+        "volumeName='" + volumeName + '\'' +
+        ", bucketName='" + bucketName + '\'' +
+        ", keyName='" + keyName + '\'' +
+        ", dataSize=" + dataSize +
+        ", keyLocationVersions=" + keyLocationVersions +
+        ", creationTime=" + creationTime +
+        ", modificationTime=" + modificationTime +
+        ", replicationConfig=" + replicationConfig +
+        ", encInfo=" + encInfo +

Review Comment:
   Encryption info seems sensitive to be logged, please check and remove this.



##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/request/key/OMKeyCommitRequest.java:
##########
@@ -242,7 +253,16 @@ public OMClientResponse 
validateAndUpdateCache(OzoneManager ozoneManager,
         if (null == oldKeyVersionsToDeleteMap) {
           oldKeyVersionsToDeleteMap = new HashMap<>();
         }
-        oldKeyVersionsToDeleteMap.put(delKeyName, oldVerKeyInfo);
+
+        // Remove any block from oldVerKeyInfo that share the same container ID
+        // and local ID with omKeyInfo blocks'.

Review Comment:
   The fix is good to avoid deletion of blocks in generic. I think actual root 
cause can also be fixed. Attached fix for this.
   
   
[hsync_delete_issue.patch](https://github.com/apache/ozone/files/12312760/hsync_delete_issue.patch)
   



-- 
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]

Reply via email to