[Tunnelbroker] close RabbitMQ queue when client disconnects
Summary:
This might cause issues and was causing error in past:
- We run persistence test
- Queue is created, but never closed
- We run tests again, messages are in database, but are also put into RabbitMQ
- Consumer receives messages, and try to send but socket is closed at this time
- It generates error in Tunnelbroker logs
Depends on D9316
Test Plan:
- Without this changes run:
cd services/commtest && cargo test --test tunnelbroker_persist_tests -- --nocapture
- Wait for the test to finish
- Go to RabbitMQ console and it shows queues:
- Restart RabbitMQ
- Do steps 1, 2, 3 and the console should show 0 queues:
Reviewers: michal, bartek, varun, jon
Reviewed By: michal, bartek
Subscribers: ashoat, tomek
Differential Revision: https://phab.comm.dev/D9317