mirror of
https://github.com/scylladb/scylladb.git
synced 2026-04-29 04:37:00 +00:00
Currently if index_node throws when trying to add an already indexed node, pop_node might unindex the existing node instead of the new one. Instead, with this change, unindex_node looks up the node by its pointer and removed it from the index map only if it's found there so to clean up safely after index_node throws (at any stage). Add a unit test to verify that. In addition, added a unit test to reproduce #13502 and test the fix. Closes #13512 * github.com:scylladb/scylladb: test: locator_topology: add test_update_node topology: add_node, unindex_node: make exception safe