Skip to content

registry: cloud_transports, how a session with FTW Cloud travels (QUIC step 2) - #91

Merged
frahlg merged 2 commits into
mainfrom
claude/registry-cloud-transports
Oct 16, 2026
Merged

frahlg merged 2 commits into
mainfrom
claude/registry-cloud-transports

Conversation

@frahlg

@frahlg frahlg commented Oct 15, 2026 •

Copy link
Copy Markdown
Member

What

One new list, edited here first as the registry rule says:

  • cloud_transports: [quic, websocket]. This is how a session with FTW Cloud travels under the tunnel and cloud carriers: QUIC on UDP 443, or the WebSocket on TCP 443 that a client falls back to. srcfl/ftw docs/protocol-cloud.md defines it in "QUIC".

It is not a carrier. The carrier still says what carries the data and who can read it: tunnel is the box's own session, cloud is the copy FTW Cloud reads. That holds over both transports. Freshness stays two fields, carrier and source state. The transport is what the box shows in GET /api/cloud and the app shows beside the carrier, so nobody has to guess which path a number came over.

The web app uses neither name yet. A browser cannot open raw QUIC; it keeps the WebSocket.

Paired PRs

QUIC step 2 (step 1 is srcfl/ftw-cloud#16, HTTP/3 for the plain routes):

Contract-pair: srcfl/ftw@feat/cloud-quic

Numbers

The full WebSocket against QUIC tables are in srcfl/ftw#1653, srcfl/ftw-cloud#22 and srcfl/ftw-app#74. At 40 ms round trip with 5 % loss on every leg, with the review's fixes in (a phone's session now waits for the QUIC handshake):

what WebSocket p50 / p95 ms QUIC p50 / p95 ms
cold connect → first live number 610 / 2057 380 / 568
reconnect → first live number 434 / 1190 385 / 585
tap → ack 104 / 360 104 / 202
network switch → live again (Go test phone) 689 (new session) 50 (same session)

Tests

No code change here. The contract job compares this file with the copy on srcfl/ftw@feat/cloud-quic.

🤖 Generated with Claude Code

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 15, 2026 •

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
ftw-webapp 86252ec Commit Preview URL

Branch Preview URL
Oct 16 2026, 05:36 AM

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-10-15T17:31:33.733555Z d4777e1 PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@frahlg
frahlg merged commit 65cb00b into main Oct 16, 2026
3 checks passed
frahlg added a commit to srcfl/ftw-app that referenced this pull request Oct 16, 2026
* iPhone: FTW Cloud over QUIC, racing the WebSocket

The app session with FTW Cloud now dials ftw-cloud-app/1 over QUIC on UDP
443 first, through Network.framework's NetworkConnection. If QUIC has not
opened after 250 ms the WebSocket starts too, and the first to open
carries the session; the winner on each network goes first next time.

- QUICCloudSocket is one WebSocketConnection: the control stream starts
  with the target, the box's bulk comes on a stream the service opens, and
  hb and live may come as datagrams. A keepalive every 15 s holds the NAT
  mapping; the service's close code comes back as the WebSocket's would.
- CloudSockets.racing and CloudTransportMemory are the race and its
  memory; NetworkWatch names the network by interfaces and gateways.
- CloudCarrier drops a message past the Noise window instead of ending
  the session, since a datagram can arrive after newer messages, and says
  how it travels. FTW Cloud's settings show "Connected · QUIC".
- Contract.cloudTransports and protocol/registry.yaml from
  srcfl/ftw-webapp#91; cloud-quic-vectors.json from srcfl/ftw.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* iPhone: a network's race winner holds for a day, and the network is kept as a hash

The simulator can run FTWKit's tests: the one shell helper is macOS only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* iPhone: a QUIC dial that loses the race goes on to learn about UDP; only the control stream ends a session

In the simulator at 5 % loss one lost QUIC handshake packet lost the race to
the WebSocket and kept QUIC second for a day. The losing QUIC dial now goes
on for up to 3 s, and if it opens, QUIC goes first next time.

The bulk streams and the datagrams no longer end the QUIC session when they
stop, as against a service that offers no datagrams.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* FTW Cloud settings: interpolate the transport, fix a doc comment

Text + Text is deprecated in iOS 26. transportName had also landed
between followErasure and its doc comment.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

* fix(cloud-quic): the review's fixes on the iPhone

- S1: the Noise replay window is 1024 (16 words), as in srcfl/ftw, since
  a bulk burst can overtake a control message. CloudCarrier drops a
  replay only when it came as a datagram (WebSocketEvents.onDatagram); on
  a stream it ends the session.
- B2/S5: a QUIC session that ends before its first message, or that the
  path drops within a minute of it, demotes QUIC on that network for a
  day, and no QUIC win moves it back meanwhile. Closes from 1000 up other
  than 1005 and 1006 do not count. CloudTransportMemory keeps only the
  last day's networks.
- S2: CloudView takes the table of a late live whose srcRev is newer and
  keeps the newer values (Freshness case 17).
- cloud-quic-vectors.json from srcfl/ftw#1653.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 5.5 <noreply@anthropic.com>
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