[QUEUED scylladb next] test: add test that checks that local address cannot expire between join request placemen and its processing

0 views
Skip to first unread message

Commit Bot

<bot@cloudius-systems.com>
unread,
Jul 1, 2024, 3:13:09 AMJul 1
to scylladb-dev@googlegroups.com, Gleb Natapov
From: Gleb Natapov <gl...@scylladb.com>
Committer: Gleb Natapov <gl...@scylladb.com>
Branch: next

test: add test that checks that local address cannot expire between join request placemen and its processing

---
diff --git a/service/storage_service.cc b/service/storage_service.cc
--- a/service/storage_service.cc
+++ b/service/storage_service.cc
@@ -1224,6 +1224,10 @@ class join_node_rpc_handshaker : public service::group0_handshaker {
rtlogger.info("join: request to join placed, waiting"
" for the response from the topology coordinator");

+ if (utils::get_local_injector().enter("pre_server_start_drop_expiring")) {
+ _ss._group0->modifiable_address_map().force_drop_expiring_entries();
+ }
+
_ss._join_node_request_done.set_value();
},
[] (const join_node_request_result::rejected& rej) {
diff --git a/test/topology_custom/test_long_join.py b/test/topology_custom/test_long_join.py
--- a/test/topology_custom/test_long_join.py
+++ b/test/topology_custom/test_long_join.py
@@ -25,3 +25,18 @@ async def test_long_join(manager: ManagerClient) -> None:
await manager.api.enable_injection(s1.ip_addr, "handle_node_transition_drop_expiring", one_shot=True)
await manager.api.message_injection(s1.ip_addr, inj)
await asyncio.gather(task)
+
+...@pytest.mark.asyncio
+async def test_long_join_drop_wntries_on_bootstrapping(manager: ManagerClient) -> None:
+ """The test checks that join works even if expiring entries are dropped
+ on the joining node between placement of the join request and its processing"""
+ s1 = await manager.server_add()
+ inj = 'topology_coordinator_pause_before_processing_backlog'
+ await manager.api.enable_injection(s1.ip_addr, inj, one_shot=True)
+ s2 = await manager.server_add(start=False, config={
+ 'error_injections_at_startup': ['pre_server_start_drop_expiring']
+ })
+ task = asyncio.create_task(manager.server_start(s2.server_id))
+ await manager.server_sees_other_server(s1.ip_addr, s2.ip_addr, interval=300)
+ await manager.api.message_injection(s1.ip_addr, inj)
+ await asyncio.gather(task)

Commit Bot

<bot@cloudius-systems.com>
unread,
Jul 1, 2024, 6:43:00 AMJul 1
to scylladb-dev@googlegroups.com, Gleb Natapov
From: Gleb Natapov <gl...@scylladb.com>
Committer: Gleb Natapov <gl...@scylladb.com>
Branch: master

Commit Bot

<bot@cloudius-systems.com>
unread,
Jul 1, 2024, 10:20:59 AMJul 1
to scylladb-dev@googlegroups.com, Gleb Natapov
From: Gleb Natapov <gl...@scylladb.com>
Committer: Mergify <37929162+mergify[bot]@users.noreply.github.com>
Branch: next-6.0

test: add test that checks that local address cannot expire between join request placemen and its processing

(cherry picked from commit 3f136cf2eb62d84dedf1ec37623af1c7e71a29dc)
Reply all
Reply to author
Forward
0 new messages