alievmirza commented on code in PR #6999:
URL: https://github.com/apache/ignite-3/pull/6999#discussion_r2540825085
##########
modules/raft/src/integrationTest/java/org/apache/ignite/raft/jraft/core/TestCluster.java:
##########
@@ -613,6 +612,71 @@ public void ensureSame(Predicate<PeerId> filter) throws
InterruptedException {
}
}
+ /**
+ * @return {@code True} if all configurations that was applied to FSM are
the same.
+ */
+ public void ensureSameConf() {
+ this.lock.lock();
+
+ List<MockStateMachine> fsmList = new ArrayList<>(this.fsms.values());
+
+ if (fsmList.size() <= 1) {
+ LOG.warn("ensureSame is skipped because only one node in the
group");
+ this.lock.unlock();
+ return;
+ }
+
+ Node leader = getLeader();
+
+ assertNotNull(leader);
+
+ MockStateMachine first = fsms.get(leader.getNodeId().getPeerId());
+
+ LOG.info("Start ensureSameConf, leader={}", leader);
+
+ try {
+ assertTrue(TestUtils.waitForCondition(() -> {
Review Comment:
done
--
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]