vldpyatkov commented on code in PR #2183: URL: https://github.com/apache/ignite-3/pull/2183#discussion_r1228652145
########## modules/distribution-zones/src/testFixtures/java/org/apache/ignite/internal/distributionzones/DistributionZonesTestUtil.java: ########## @@ -313,17 +313,17 @@ public static void deployWatchesAndUpdateMetaStorageRevision(MetaStorageManager throws NodeStoppingException, InterruptedException { // Watches are deployed before distributionZoneManager start in order to update Meta Storage revision before // distributionZoneManager's recovery. - metaStorageManager.deployWatches(); + var deployWatchesFut = metaStorageManager.deployWatches(); // Bump Meta Storage applied revision by modifying a fake key. DistributionZoneManager breaks on start if Vault is not empty, but // Meta Storage revision is equal to 0. var fakeKey = new ByteArray("foobar"); - CompletableFuture<Boolean> invokeFuture = metaStorageManager.invoke( + CompletableFuture<Boolean> invokeFuture = deployWatchesFut.thenCompose(unused -> metaStorageManager.invoke( Review Comment: I think, if before, we have no guarantees that MC start earlier than watches subscribe, it means thus tests are buggy. Ok, add synchronous waiting in every invocation. -- 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