You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by GitBox <gi...@apache.org> on 2021/03/16 17:01:08 UTC

[GitHub] [accumulo] EdColeman commented on a change in pull request #1972: Add specific types for Fate locks and Zoo locks

EdColeman commented on a change in pull request #1972:
URL: https://github.com/apache/accumulo/pull/1972#discussion_r595367674



##########
File path: core/src/main/java/org/apache/accumulo/fate/zookeeper/ZooLock.java
##########
@@ -60,6 +60,19 @@ public String toString() {
 
   }
 
+  public static class ZooLockPath {
+    private final String path;
+
+    public ZooLockPath(String path) {
+      this.path = path;
+    }
+
+    @Override
+    public String toString() {
+      return this.path;
+    }
+  }
+

Review comment:
       Just a general observation - would it improve readability if in addition to toString() that there was a getter (getPath())? 
   
   Also, did you notice places where the node name was necessary?  If so, then would things be cleaner if there was a getNode() or something that did the parsing?  Might save a few lines here and there - but would gather that code into a single place.




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

For queries about this service, please contact Infrastructure at:
users@infra.apache.org