rpuch commented on code in PR #4315:
URL: https://github.com/apache/ignite-3/pull/4315#discussion_r1739836915


##########
modules/system-disaster-recovery/src/integrationTest/java/org/apache/ignite/internal/disaster/system/ItCmgDisasterRecoveryTest.java:
##########
@@ -111,6 +128,11 @@ private CompletableFuture<Void> 
restartOrShutdownFuture(int nodeIndex) {
         return ((IgniteServerImpl) 
cluster.server(nodeIndex)).restartOrShutdownFuture();
     }
 
+    private static ClusterState clusterState(IgniteImpl restartedIgniteImpl1)
+            throws InterruptedException, ExecutionException, TimeoutException {
+        return 
restartedIgniteImpl1.clusterManagementGroupManager().clusterState().get(10, 
SECONDS);

Review Comment:
   `.get(...)` declares checked exceptions. In `findLeaderNode()` we would have 
to handle them with a try/catch, bloating the 'just one line' to 'many lines'. 
But I used this in contexts where we can just declare those `throws` ourselves, 
so the bloating does not happen.



-- 
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: notifications-unsubscr...@ignite.apache.org

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

Reply via email to