Skip to content

Stop exporting a stale dialled URL to the stream hooks - #42

Merged
chrisuthe merged 1 commit into
mainfrom
fix/stale-server-url
Aug 28, 2026
Merged

chrisuthe merged 1 commit into
mainfrom
fix/stale-server-url

Conversation

@chrisuthe

Copy link
Copy Markdown
Member

SENDSPIN_SERVER_URL is documented as the URL this run dialled, but -s leaves the inbound listener up, and the library reports that a connection is up without saying where it came from. Once any dial had been attempted, a server that dialled in afterwards produced a stream whose hooks exported the URL of that earlier attempt -- a URL with no relation to the connection the stream arrived on (refs #34).

The dial is now remembered together with what can contradict it. Losing the connection forgets it: whatever the URL described is gone, and no answer beats a stale one. A discovery dial also knows which server_id it dialled -- the mDNS instance label is the protocol server_id, the same equality the remembered-server preference stands on -- so its URL is exported only when the stream arrived from that server. A literal -s URL still cannot be verified against the connection; ruling that case out needs the library to name the live connection's origin, which nothing it exposes today can.

SENDSPIN_SERVER_URL is documented as the URL this run dialled, but -s
leaves the inbound listener up, and the library reports that a
connection is up without saying where it came from. Once any dial had
been attempted, a server that dialled in afterwards produced a stream
whose hooks exported the URL of that earlier attempt -- a URL with no
relation to the connection the stream arrived on (refs #34).

The dial is now remembered together with what can contradict it. Losing
the connection forgets it: whatever the URL described is gone, and no
answer beats a stale one. A discovery dial also knows which server_id
it dialled -- the mDNS instance label is the protocol server_id, the
same equality the remembered-server preference stands on -- so its URL
is exported only when the stream arrived from that server. A literal
-s URL still cannot be verified against the connection; ruling that
case out needs the library to name the live connection's origin, which
nothing it exposes today can.
@chrisuthe
chrisuthe merged commit 9e60ab9 into main Aug 28, 2026
12 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant