Pārlūkot izejas kodu

HDDS-404. Implement toString() in OmKeyLocationInfo. Contributed by Dinesh Chitlangia.

Márton Elek 6 gadi atpakaļ
vecāks
revīzija
b6c543fe45

+ 10 - 0
hadoop-ozone/common/src/main/java/org/apache/hadoop/ozone/om/helpers/OmKeyLocationInfo.java

@@ -130,4 +130,14 @@ public final class OmKeyLocationInfo {
     info.setCreateVersion(keyLocation.getCreateVersion());
     return info;
   }
+
+  @Override
+  public String toString() {
+    return "{blockID={containerID=" + blockID.getContainerID() +
+        ", localID=" + blockID.getLocalID() + "}" +
+        ", shouldCreateContainer=" + shouldCreateContainer +
+        ", length=" + length +
+        ", offset=" + offset +
+        ", createVersion=" + createVersion + '}';
+  }
 }