ctubbsii commented on code in PR #2990:
URL: https://github.com/apache/accumulo/pull/2990#discussion_r984813616


##########
server/manager/src/main/java/org/apache/accumulo/manager/Manager.java:
##########
@@ -207,7 +208,7 @@ public class Manager extends AbstractServer
 
   private ManagerState state = ManagerState.INITIAL;
 
-  Fate<Manager> fate;
+  private final AtomicReference<Fate<Manager>> fateReady = new 
AtomicReference<>(null);
 

Review Comment:
   I considered that, but having the fate object and the countdownlatch in 
separate variables means that separate threads wouldn't necessarily see the 
updated fate object unless I also made that voloatile, which seemed redundant. 
The best way to do it seemed to have the volatile reference be the same object 
that is monitored for readiness.



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