swamirishi commented on code in PR #6923:
URL: https://github.com/apache/ozone/pull/6923#discussion_r1690615593


##########
hadoop-hdds/container-service/src/main/java/org/apache/hadoop/ozone/container/keyvalue/impl/FilePerBlockStrategy.java:
##########
@@ -307,11 +304,14 @@ public FileChannel getChannel(File file, boolean sync)
       }
     }
 
-    private static OpenFile open(File file, boolean sync) {
+    private static OpenFile open(Container container, BlockID blockID, boolean 
sync) {
       try {
+        File file = getChunkFile(container, blockID);
         return new OpenFile(file, sync);
       } catch (FileNotFoundException e) {
         throw new UncheckedIOException(e);
+      } catch (StorageContainerException e) {
+        throw new UncheckedIOException(e);
       }
     }
 

Review Comment:
   The close & isOpen function in line 318 & 324 respectively need to have the 
argument of class ContainerBlockId and not File since the key of the cache has 
changed.



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