Cyrill commented on code in PR #3496:
URL: https://github.com/apache/ignite-3/pull/3496#discussion_r1547617897
##########
modules/runner/src/integrationTest/java/org/apache/ignite/internal/table/ItDurableFinishTest.java:
##########
@@ -314,6 +319,58 @@ private void markTxAbortedInTxStateStorage(IgniteImpl
primaryNode, InternalTrans
storage.put(tx.id(), txMetaToSet);
}
+
+ @Test
+ void testCleanupReplicatedMessage() throws ExecutionException,
InterruptedException {
+ Context context = prepareTransactionData();
+
+
+ DefaultMessagingService primaryMessaging =
messaging(context.primaryNode);
+
+ CompletableFuture<Void> cleanupReplicatedFuture = new
CompletableFuture<>();
+
+ primaryMessaging.dropMessages((s, networkMessage) -> {
+ if (networkMessage instanceof TxCleanupMessageResponse) {
+ logger().info("Received message: {}.", networkMessage);
+
+ TxCleanupMessageResponse message = (TxCleanupMessageResponse)
networkMessage;
+
+ if (message instanceof TxCleanupMessageErrorResponse) {
+ TxCleanupMessageErrorResponse error =
(TxCleanupMessageErrorResponse) message;
+
+ logger().error("Cleanup Error: ", error);
+
+ return false;
+ }
+
+ Object result = message.result();
+
+ if (result != null) {
+ cleanupReplicatedFuture.complete(null);
+ }
+ }
+
+ return false;
+ });
+
+ commitAndValidate(context.tx, context.tbl, context.keyTpl);
+
+ for (CompletableFuture<?> future : futures) {
Review Comment:
removed.
--
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]