GeorgeJahad commented on code in PR #5106:
URL: https://github.com/apache/ozone/pull/5106#discussion_r1272600336


##########
hadoop-ozone/ozone-manager/src/main/java/org/apache/hadoop/ozone/om/OMDBCheckpointServlet.java:
##########
@@ -389,6 +395,19 @@ private void writeFilesToArchive(Set<Path> copyFiles,
     }
   }
 
+  @NotNull
+  private static Path getVerifiedCheckPointPath(Path checkpointLocation) {
+    Path metaDirPath = checkpointLocation;
+    // This check is done to take care of findbug else below getParent()
+    // should not be null.
+    Path locationParent = checkpointLocation.getParent();
+    if (null != locationParent) {
+      Path parent = locationParent.getParent();
+      metaDirPath = parent != null ? parent : locationParent;

Review Comment:
   This should throw a null pointer exception.  switching it back to 
locationParent will cause a more confusing error.



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