Page MenuHomePhabricator

[Tunnelbroker] Refactor connection lifetimes into session object

Authored by jon on May 12 2023, 2:32 PM.
Referenced Files
F1865421: D7800.diff
Sun, May 26, 9:58 AM
Unknown Object (File)
Thu, May 23, 9:47 PM
Unknown Object (File)
Mon, May 13, 10:58 AM
Unknown Object (File)
Wed, May 8, 6:57 PM
Unknown Object (File)
Tue, May 7, 7:58 PM
Unknown Object (File)
Mon, May 6, 4:30 PM
Unknown Object (File)
Mon, May 6, 1:41 PM
Unknown Object (File)
Sun, May 5, 9:18 PM



For better encapsulation around connection events
(e.g. device being authenticated and identified), moved
more of the connection logic into the session object.

Also, refine how connections are handled so they are properly
deregistered once a client closes a connection.

Depends on D7799

Test Plan
nix develop

# init localstack and run terraform
comm-dev services start
(cd services/terraform && ./

(cd services/tunnelbroker && cargo run &)
(cd services/commtest && cargo test --test tunnelbroker_integration_test)
# Previously, running the suite twice would fail
(cd services/commtest && cargo test --test tunnelbroker_integration_test)

Diff Detail

rCOMM Comm
Lint Not Applicable
Tests Not Applicable

Event Timeline

108 ↗(On Diff #26422)

These unwraps get handled in the next diff.

Just a lot of boilerplate to handle this nicely.

This revision is now accepted and ready to land.May 30 2023, 6:30 AM

Rebase on previous changes