Skip to content

Conversation

Bouncheck
Copy link

Moves additional sessions used in this test into try-with-resources statements, ensuring that they are closed afterwards.

Fixes #678.

@Bouncheck Bouncheck self-assigned this Oct 2, 2025
@Bouncheck Bouncheck force-pushed the scylla-4.x-DefaultMetadataTabletMapIT-put-sessions-into-try-w-resources branch 3 times, most recently from 50454e7 to b1dd53c Compare October 2, 2025 19:41
@Bouncheck
Copy link
Author

Bouncheck commented Oct 2, 2025

I'm not sure why the produced diff looks so utterly confusing, but what this change does is truly just move sessions into variables inside resources sections (and apply formatter).
I have already rebased all my branches.
edit: also the Suppliers in sessions map slightly changed. Each supplier used to create a new session and now it uses a single instance per Supplier instead. If it was important i can roll that back to creating a new instance for each query.

@Bouncheck
Copy link
Author

Bouncheck commented Oct 2, 2025

I see bind exceptions in the logs and that the shard awareness test is still failing (but only for 1 job instead of 3), so maybe it is worth making it less heavy.
Good news is that the change seems to be working because there are no external sessions trying to reconnect to 127.0.18. anymore.

Moves additional sessions used in this test into try-with-resources
statements, ensuring that they are closed afterwards.
Adding as a separate commit because otherwise the diff is hard to
understand in contrast to what it actually does.
@Bouncheck Bouncheck force-pushed the scylla-4.x-DefaultMetadataTabletMapIT-put-sessions-into-try-w-resources branch from b1dd53c to 690831c Compare October 6, 2025 12:53
@Bouncheck
Copy link
Author

Rebased on top of scylla-4.x.
See first commit for readable changes without extra indentation.
The hashmap with Suppliers of Sessions is back to how it used to be before the first version of this PR. Added try in a different place instead.

@dkropachev dkropachev merged commit 43178b0 into scylladb:scylla-4.x Oct 6, 2025
9 of 11 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4.x: DefaultMetadataTabletMapIT leaves multiple hanging sessions

2 participants