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)
Sun, Sep 15, 1:38 PM
Unknown Object (File)
Sun, Sep 15, 1:38 PM
Unknown Object (File)
Sun, Sep 15, 1:38 PM
Unknown Object (File)
Sun, Sep 15, 1:35 PM
Unknown Object (File)
Aug 26 2024, 7:42 PM
Unknown Object (File)
Aug 26 2024, 2:18 AM
Unknown Object (File)
Aug 25 2024, 1:34 PM
Unknown Object (File)
Aug 25 2024, 7:03 AM
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
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

bartek held this revision as a draft.
michal added inline comments.
services/tunnelbroker/src/websockets/mod.rs
96–99 ↗(On Diff #30994)

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 ↗(On Diff #30994)

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.