Perfect. You’ve got 7 hours, a clean goal, and a dev-focused mindset — let’s make every hour count.
We’ll keep it bare metal, minimal setup, and aim for speed + understanding (not production-level security yet).
Stack: WebTransport (QUIC over HTTP/3)
Interface: Command-line
Goal: Send any file, chunked + resumable, directly peer-to-peer (or via local relay server).
| Layer | Component | Purpose |
|---|---|---|
| Protocol | WebTransport | Stream-based reliable file transfer over QUIC |
| Server | Node.js (v18+ with experimental WebTransport) | Handles incoming file chunks |
| Client | Node.js CLI | Splits + streams files via WebTransport |
| CLI | Commander.js | Simple command-based interface |
| Utils | fs, stream, buffer, perf_hooks | File I/O + chunk handling |
| Optional | express + @fails-components/webtransport | Easier server setup |
| Testing | localhost or LAN IP | Zero-latency dev setup |
Goal: Both systems can communicate over WebTransport.
Tasks:
Install Node 18+ (needed for experimental QUIC APIs).
Enable QUIC:
node --experimental-quic --experimental-webtransport server.js
Create minimal WebTransport server:
// server.js
import { WebTransportServer } from 'webtransport';
const server = new WebTransportServer({ port: 8000 });
server.on('session', s => console.log('session connected'));
Connect from client with:
// client.js
const wt = new WebTransport('https://<your-ip>:8000');
await wt.ready;
console.log('Connected!');
✅ Checkpoint: You see “session connected” on both laptops.