From 0e3867a9f40a3d3704fdae90ac51c02191eaf0c1 Mon Sep 17 00:00:00 2001 From: Sam Tunnicliffe Date: Thu, 30 May 2024 15:43:00 +0100 Subject: [PATCH] Ignore harmless error message if system_auth reads occur during an rf change Patch by Sam Tunnicliffe; reviewed by XXX for CASSANDRA-19217 --- auth_test.py | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/auth_test.py b/auth_test.py index ea1ad31aef..1f0dec102c 100644 --- a/auth_test.py +++ b/auth_test.py @@ -2792,6 +2792,19 @@ class TestAuthUnavailable(AbstractTestAuth): * release regimes. """ + @pytest.fixture(autouse=True) + def fixture_add_additional_log_patterns(self, fixture_dtest_setup): + fixture_dtest_setup.ignore_log_patterns = ( + # This occurs if a client interaction which results in a specific type of query on system_auth, happens to + # run concurrently with changing the rf from 1 to 2. For example, a query to read the default `cassandra` + # superuser will execute at CL.QUORUM. If this query is issued before the rf change, the replica plan will + # contain only 1 node. Should the rf change be enacted before the response is processed by the coordinator, + # that original replica plan will no longer be sufficient to satisfy the consistency level, as now QUORUM is + # (2/2 + 1) = 2. This does not affect the actual test as the client will retry in this case and as the + # placements remain stable after the initial rf change, subsequent reads will succeed. + r'.* for keyspace system_auth at QUORUM the ring has changed .* in a way that would make responses violate the consistency level', + ) + def test_authentication_handle_unavailable(self): """ * Launch a two node cluster with role/permissions cache disabled