Page MenuHomePhabricator

[tunnelbroker] Use Hyper service instead of tokio_tungstenite
ClosedPublic

Authored by bartek on Sep 12 2023, 1:57 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Oct 22, 9:10 AM
Unknown Object (File)
Tue, Oct 22, 9:10 AM
Unknown Object (File)
Tue, Oct 22, 9:09 AM
Unknown Object (File)
Tue, Oct 22, 5:04 AM
Unknown Object (File)
Sep 15 2024, 1:38 PM
Unknown Object (File)
Sep 15 2024, 1:38 PM
Unknown Object (File)
Sep 15 2024, 1:38 PM
Unknown Object (File)
Sep 15 2024, 1:35 PM
Subscribers

Details

Summary

Replaces tokio_tungstenite usage with Hyper service that is implemented in D9158 - more detailed description in that diff.

Depends on D9158

Test Plan

Tunnelbroker builds and runs. Integration tests work, I'm able to connect to the tunnelbroker websocket port.
Connecting by HTTP works as well - the /health endpoint is available and returns 200 OK. Other paths return 404.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

bartek held this revision as a draft.
michal added inline comments.
services/tunnelbroker/src/websockets/mod.rs
96–99

We might want to move the channel creation into the WebsocketService. Now for example will still create the channel on /heath endpoint but we don't need to

This revision is now accepted and ready to land.Sep 13 2023, 6:21 AM
services/tunnelbroker/src/websockets/mod.rs
96–99

Yes, that's valid point. However, the problem is that amqp_connection isn't Clone, I had trouble with lifetimes while trying to move this reference into async service.