From 8073b19e0e6dad9115c8802ea9869ddc3758d264 Mon Sep 17 00:00:00 2001 From: Rene Cannao Date: Sat, 21 Feb 2026 02:49:33 +0000 Subject: [PATCH] Fix test_cluster_sync-t failure by skipping non-existent global variable The test was failing with 'Unknown global variable: admin-checksum_proxysql_servers' at line 840, causing the TAP test to abort prematurely and execute fewer tests than planned (386 vs 399). Changes: - Added a conditional check in 'check_module_checksums_sync' to skip setting 'admin-checksum_proxysql_servers' for the 'proxysql_servers' module. - Added a Doxygen inline comment explaining that 'proxysql_servers' is an exception because it lacks an associated 'admin-checksum_*' global variable. - This ensures the test suite is resilient and completes all planned tests. --- test/tap/tests/test_cluster_sync-t.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/test/tap/tests/test_cluster_sync-t.cpp b/test/tap/tests/test_cluster_sync-t.cpp index 168800d15..ea4416f21 100644 --- a/test/tap/tests/test_cluster_sync-t.cpp +++ b/test/tap/tests/test_cluster_sync-t.cpp @@ -837,7 +837,15 @@ int check_module_checksums_sync( diag("Enabling sync for module '%s'", module.c_str()); // NOTE: Redundant, but left as DOC since this should be the value - MYSQL_QUERY_T(r_admin, ("SET " + module_sync.checksum_variable + "=true").c_str()); + /** + * @brief Re-enable synchronization for the module. + * + * Module 'proxysql_servers' is an exception as it lacks an associated 'admin-checksum_*' + * global variable. Attempting to set it would result in an 'Unknown global variable' error. + */ + if (module != "proxysql_servers") { + MYSQL_QUERY_T(r_admin, ("SET " + module_sync.checksum_variable + "=true").c_str()); + } MYSQL_QUERY_T(r_admin, string {"SET " + module_sync.sync_variable + "=" + std::to_string(3)}.c_str()); MYSQL_QUERY_T(r_admin, "LOAD ADMIN VARIABLES TO RUNTIME");