From 9704d230faa6a1e4ffd06276323cf8ee4f831fe3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-S=C3=A9bastien=20P=C3=A9dron?= Date: Fri, 4 Apr 2025 15:01:57 +0200 Subject: [PATCH 1/2] quorum_queue_SUITE: Improve reliability of a test ... by waiting for a state. --- deps/rabbit/test/quorum_queue_SUITE.erl | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/deps/rabbit/test/quorum_queue_SUITE.erl b/deps/rabbit/test/quorum_queue_SUITE.erl index 56e5f4a710c8..1a73290e463e 100644 --- a/deps/rabbit/test/quorum_queue_SUITE.erl +++ b/deps/rabbit/test/quorum_queue_SUITE.erl @@ -2485,11 +2485,21 @@ confirm_availability_on_leader_change(Config) -> ok. wait_for_new_messages(Config, Node, Name, Increase) -> + wait_for_new_messages(Config, Node, Name, Increase, 60000). + +wait_for_new_messages(Config, Node, Name, Increase, Timeout) -> Infos = rabbit_ct_broker_helpers:rabbitmqctl_list( Config, Node, ["list_queues", "name", "messages"]), - [[Name, Msgs0]] = [Props || Props <- Infos, hd(Props) == Name], - Msgs = binary_to_integer(Msgs0), - queue_utils:wait_for_min_messages(Config, Name, Msgs + Increase). + case [Props || Props <- Infos, hd(Props) == Name] of + [[Name, Msgs0]] -> + Msgs = binary_to_integer(Msgs0), + queue_utils:wait_for_min_messages(Config, Name, Msgs + Increase); + _ when Timeout >= 0 -> + Sleep = 200, + timer:sleep(Sleep), + wait_for_new_messages( + Config, Node, Name, Increase, Timeout - Sleep) + end. flush(T) -> receive X -> From 860d9fcd9cfc5a75093c159a192cb6ef9812b778 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jean-S=C3=A9bastien=20P=C3=A9dron?= Date: Fri, 4 Apr 2025 11:15:47 +0200 Subject: [PATCH 2/2] Update khepri_mnesia_migration from 0.7.1 to 0.7.2 Release notes: https://github.com/rabbitmq/khepri_mnesia_migration/releases/tag/v0.7.2 In particular, it makes sure that the Erlang node with the lowest Khepri machine version is use as the cluster seed node. Otherwise these nodes would not be able to apply commands from newer Khepri machines. See rabbitmq/khepri_mnesia_migration#30. --- rabbitmq-components.mk | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rabbitmq-components.mk b/rabbitmq-components.mk index b28f08f37199..5d3683e4569f 100644 --- a/rabbitmq-components.mk +++ b/rabbitmq-components.mk @@ -47,7 +47,7 @@ dep_cuttlefish = hex 3.4.0 dep_gen_batch_server = hex 0.8.8 dep_jose = hex 1.11.10 dep_khepri = hex 0.16.0 -dep_khepri_mnesia_migration = hex 0.7.1 +dep_khepri_mnesia_migration = hex 0.7.2 dep_meck = hex 1.0.0 dep_osiris = git https://github.com/rabbitmq/osiris v1.8.6 dep_prometheus = hex 4.11.0