ibessonov commented on code in PR #7016:
URL: https://github.com/apache/ignite-3/pull/7016#discussion_r2542382198
##########
modules/raft/src/integrationTest/java/org/apache/ignite/internal/raftsnapshot/ItTableRaftSnapshotsTest.java:
##########
@@ -613,6 +646,24 @@ private BiPredicate<String, NetworkMessage>
dropSnapshotMetaResponse(Completable
};
}
+ private BiPredicate<String, NetworkMessage> dropSnapshotMvDataResponse(
+ int targetNodeIndex,
+ CompletableFuture<Void> sentFirstSnapshotMvDataResponse
+ ) {
+ String node2Name = cluster.node(targetNodeIndex).name();
Review Comment:
Why ` node2`? Where's node one?
##########
modules/raft/src/integrationTest/java/org/apache/ignite/internal/raftsnapshot/ItTableRaftSnapshotsTest.java:
##########
@@ -712,6 +763,50 @@ void testChangeLeaderOnInstallSnapshotInMiddle() throws
Exception {
assertThat(getFromNode(2, 1), is("one"));
}
+ @Disabled("https://issues.apache.org/jira/browse/IGNITE-26849")
+ @Test
+ void testRestartNodeAfterTruncateRaftLogPrefixAndAbortRebalance() throws
Exception {
+ createTestTableWith3Replicas(DEFAULT_STORAGE_ENGINE);
+
+ transferLeadershipOnSolePartitionTo(0);
+
+ putToNode(0, 1, "one");
+ putToNode(0, 2, "two");
+
+ // Let's take RAFT snapshots and truncate RAFT log prefix on all nodes.
+ causeLogTruncationOnSolePartition(0);
+ causeLogTruncationOnSolePartition(1);
+ causeLogTruncationOnSolePartition(2);
+
+ // We will cancel (stopping node) the rebalance immediately after it
starts for storages.
+ var sentFirstSnapshotMvDataResponseFormNode0Future = new
CompletableFuture<Void>();
+
unwrapIgniteImpl(cluster.node(0)).dropMessages(dropSnapshotMvDataResponse(2,
sentFirstSnapshotMvDataResponseFormNode0Future));
+
+ knockoutNode(2);
+
+ // Let's add more inserts and truncate the RAFT log to initiate a
rebalance on the returning node.
+ putToNode(0, 3, "three");
+ putToNode(0, 4, "four");
+
+ causeLogTruncationOnSolePartition(0);
+
+ reanimateNode(2);
+
+ assertThat(sentFirstSnapshotMvDataResponseFormNode0Future,
willSucceedIn(1, TimeUnit.MINUTES));
Review Comment:
Could you please leave a comment that would explain why the timeout is so
long?
--
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]