Bill commented on a change in pull request #5422:
URL: https://github.com/apache/geode/pull/5422#discussion_r466543551



##########
File path: 
geode-membership/src/main/java/org/apache/geode/distributed/internal/membership/gms/locator/PrimaryHandler.java
##########
@@ -39,9 +39,17 @@
   private TcpServer tcpServer;
   private int locatorWaitTime;
 
-  PrimaryHandler(TcpHandler fallbackHandler, int locatorWaitTime) {
+  @FunctionalInterface
+  interface Sleeper {
+    void sleep(long msToSleep) throws InterruptedException;
+  }
+
+  private Sleeper sleeper;
+
+  PrimaryHandler(TcpHandler fallbackHandler, int locatorWaitTime, Sleeper 
sleeper) {

Review comment:
       Injecting the sleeper is a good idea




----------------------------------------------------------------
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:
us...@infra.apache.org


Reply via email to