szetszwo commented on code in PR #5974:
URL: https://github.com/apache/hadoop/pull/5974#discussion_r1300668156


##########
hadoop-hdfs-project/hadoop-hdfs/src/main/java/org/apache/hadoop/hdfs/server/datanode/LocalReplica.java:
##########
@@ -367,12 +367,23 @@ public void setPinning(LocalFileSystem localFS) throws 
IOException {
   }
 
   @Override
-  public void bumpReplicaGS(long newGS) throws IOException {
+  public void bumpReplicaGS(long newGS, String trashDir) throws IOException {
     long oldGS = getGenerationStamp();
     final File oldmeta = getMetaFile();
     setGenerationStamp(newGS);
     final File newmeta = getMetaFile();
 
+    if (trashDir != null) {

Review Comment:
   @umamaheswararao , thanks a lot for reviewing this!  You are right.  It 
should not copy again if the block already exists in trash.  Updated the code.



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