Page MenuHomePhabricator

[lib] implement creating Tunnelbroker socket
ClosedPublic

Authored by kamil on Oct 26 2023, 8:56 AM.
Tags
None
Referenced Files
F3248989: D9607.id32626.diff
Fri, Nov 15, 11:45 AM
Unknown Object (File)
Mon, Nov 11, 8:21 PM
Unknown Object (File)
Fri, Nov 1, 6:02 AM
Unknown Object (File)
Sun, Oct 20, 4:15 AM
Unknown Object (File)
Fri, Oct 18, 9:02 PM
Unknown Object (File)
Oct 5 2024, 5:22 AM
Unknown Object (File)
Oct 5 2024, 3:25 AM
Unknown Object (File)
Oct 2 2024, 1:07 PM
Subscribers

Details

Summary

Creates socket and implement initial handlers.

Depends on D9606

Test Plan

Tested in next diff.

Diff Detail

Repository
rCOMM Comm
Lint
No Lint Coverage
Unit
No Test Coverage

Event Timeline

kamil held this revision as a draft.
kamil published this revision for review.Oct 27 2023, 5:37 AM
kamil added inline comments.
lib/facts/tunnelbroker.js
6 ↗(On Diff #32429)

I'll change this to staging after deployment and landing this stack, for now, I preferer this - it's easier for me to work on this.

lib/tunnelbroker/tunnelbroker-context.js
50–53 ↗(On Diff #32429)

We should retry here, but I want to avoid unnecessary computation on the client right now, when the socket most likely will be closed because the clients are not logged in to Identity and auth will fail. Improving this is tracked here.

michal added inline comments.
lib/facts/tunnelbroker.js
6 ↗(On Diff #32429)

Nit: can we change it to localhost?

lib/tunnelbroker/tunnelbroker-context.js
54–56 ↗(On Diff #32429)

Should we close the connection here?

This revision is now accepted and ready to land.Oct 30 2023, 10:00 AM

use localhost

lib/facts/tunnelbroker.js
6 ↗(On Diff #32429)

yes!

lib/tunnelbroker/tunnelbroker-context.js
54–56 ↗(On Diff #32429)

As far as I know close and error comes along, but close is later (as a result of error) so it's usually better to handle only close events. link to standard

move createTunnelbrokerSocket to tunnelbroker-context.js