-
Notifications
You must be signed in to change notification settings - Fork 171
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
refactor(iroh-relay)!: Remove relay_endpoint
config option & rename /derp
route to /relay
#2419
Conversation
any chance we can have a small test, to make sure both urls work? |
Yes! Had that planned but forgot about it? I remember looking into it, probably means I'll need to make the URL it dials configurable in the code - possibly passing it in at the Which also reminds me: Would it make sense to include the |
I think this would actually be really good, as it would allow more interesting deployments setups |
Let's continue the discussion here. |
8b40c70
to
58305bf
Compare
Yeah, I think So I would not put the |
58305bf
to
d0de17f
Compare
… `/derp` route to `/relay` But still keep accepting connections over `/derp` for backwards compatibility.
9fb48a4
to
69fb5ef
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM but I wonder if this should be split up in two PRs: the server-side and switching the client. We need to be pretty sure that we have deployed the new relay server before we release with the client switched. I'd even do them in two subsequent releases. /cc @Arqu
Good idea. Probably not hard to do. |
I split out #2441 |
/// (over websockets and a custom upgrade protocol). | ||
pub const RELAY_PATH: &str = "/relay"; | ||
/// The HTTP path under which the relay allows doing latency queries for testing. | ||
pub const RELAY_PROBE_PATH: &str = "/relay/probe"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So this is just bikesheeding, but nesting /relay/probe
is a bit odd, given the other handlers are all on the root (I appreciate this was copied from tailscale). I'd move this to /probe
so it is on the same level as /generate_204
etc. We can definitely do this for the new route. We can even remove /derp/probe
if we want as it's not yet used (hi https-probe that still lives in a half-dead branch 😓 ).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll keep it in this PR as a refactor instead of a change - let's talk about moving it when we're making use of it :)
…f `/derp` (#2441) Split out from #2419 Splitting this out means we can deploy the relay changes one release in advance to the changes in the client. Otherwise, we'd need to update the relays ASAP when we release 0.20, as clients will expect to be able to connect to the `/relay` route (which may not be deployed immediately after the release). ## Description - Switches the client to connect to `/relay` instead of `/derp`. ## Breaking Changes None ## Notes & open questions Also a PR related to #2378 I allowed myself to add in another `derive_more::Debug` instance instead of a custom, outdated `impl Debug`, if that's okay with you 😁 ## Change checklist - [X] Self-review. - [X] Documentation updates if relevant. - [X] Tests if relevant. - [X] All breaking changes documented.
…f `/derp` (#2489) Split out from #2419, copy of #2441, because I forgot to switch the base branch 🙃 Splitting this out means we can deploy the relay changes one release in advance to the changes in the client. Otherwise, we'd need to update the relays ASAP when we release 0.20, as clients will expect to be able to connect to the `/relay` route (which may not be deployed immediately after the release). ## Description - Switches the client to connect to `/relay` instead of `/derp`. ## Breaking Changes None ## Notes & open questions Also a PR related to #2378 I allowed myself to add in another `derive_more::Debug` instance instead of a custom, outdated `impl Debug`, if that's okay with you 😁 ## Change checklist - [X] Self-review. - [X] Documentation updates if relevant. - [X] Tests if relevant. - [X] All breaking changes documented.
Description
relay_endpoint
config option fromServerBuilder
iroh-relay
accept both/derp
and/relay
as paths for relaying/relay
the default path used in the iroh-net clientTODO:
Breaking Changes
iroh_net::relay::http::ServerBuilder
: Removedrelay_endpoint
functionNotes & open questions
Closes #2378
✅ Merge this after #2387
Change checklist