ctubbsii commented on a change in pull request #2470:
URL: https://github.com/apache/accumulo/pull/2470#discussion_r800979843



##########
File path: server/manager/src/main/java/org/apache/accumulo/manager/Manager.java
##########
@@ -1142,8 +1142,10 @@ boolean canSuspendTablets() {
     }
 
     try {
-      final AgeOffStore<Manager> store = new AgeOffStore<>(new 
org.apache.accumulo.fate.ZooStore<>(
-          getZooKeeperRoot() + Constants.ZFATE, context.getZooReaderWriter()), 
1000 * 60 * 60 * 8);
+      final AgeOffStore<Manager> store = new AgeOffStore<>(
+          new org.apache.accumulo.fate.ZooStore<>(getZooKeeperRoot() + 
Constants.ZFATE,
+              context.getZooReaderWriter()),
+          1000 * 60 * 60 * 8, System::currentTimeMillis);

Review comment:
       Not super important here, but when I see stuff like these multipliers, I 
find that it's a great opportunity to swap out with something more clear, like:
   ```suggestion
             TimeUnit.HOURS.toMillis(8), System::currentTimeMillis);
   ```

##########
File path: core/src/main/java/org/apache/accumulo/fate/ZooStore.java
##########
@@ -111,6 +111,11 @@ public ZooStore(String path, ZooReaderWriter zk) throws 
KeeperException, Interru
     zk.putPersistentData(path, new byte[0], NodeExistsPolicy.SKIP);
   }
 
+  /**
+   * For testing only
+   */
+  public ZooStore() {}
+

Review comment:
       This can be package-private if the tests that use it are all unit tests 
in the same package.




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


Reply via email to