Ionosphere.tv
3
fork

Configure Feed

Select the types of activity you want to include in your feed.

fix: expand public Jetstream to all tv.ionosphere.* collections

Subscribe to all ionosphere collections from any DID (not just
comments). This discovers new commenters and any future record types.

Also removed the 60s skip-to-now — ionosphere event volume is tiny,
safe to replay up to 72h of Jetstream history on restart.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>

+21 -8
+1 -1
apps/ionosphere-appview/src/appview.ts
··· 76 76 77 77 const publicJetstream = startPublicJetstream(db); 78 78 publicJetstream.start(); 79 - console.log("Public Jetstream: listening for tv.ionosphere.comment"); 79 + console.log("Public Jetstream: listening for tv.ionosphere.* from all DIDs"); 80 80 } 81 81 82 82 // ── HTTP server ───────────────────────────────────────────────────────────────
+20 -7
apps/ionosphere-appview/src/public-jetstream.ts
··· 17 17 const row = db.prepare("SELECT cursor_us FROM _public_cursor WHERE id = 1").get() as any; 18 18 const cursor = row?.cursor_us ?? null; 19 19 20 - // If cursor is more than 60 seconds behind, skip to now. 21 - // The public firehose is too large to replay — we'd rather miss 22 - // old comments than be permanently behind. 20 + // The public Jetstream is filtered to tv.ionosphere.* collections only, 21 + // so volume is tiny — safe to replay up to 72h (Jetstream retention limit). 22 + // Only skip if cursor is older than that. 23 23 if (cursor !== null) { 24 24 const nowUs = Date.now() * 1000; 25 25 const behindS = (nowUs - cursor) / 1e6; 26 - if (behindS > 60) { 27 - console.log(`[Public Jetstream] Cursor ${behindS.toFixed(0)}s behind, skipping to now`); 28 - return null; // null = start from live 26 + if (behindS > 72 * 3600) { 27 + console.log(`[Public Jetstream] Cursor ${(behindS / 3600).toFixed(0)}h behind (>72h), skipping to now`); 28 + return null; 29 29 } 30 + console.log(`[Public Jetstream] Replaying from ${(behindS / 60).toFixed(0)}min ago`); 30 31 } 31 32 32 33 return cursor; ··· 38 39 39 40 const client = new JetstreamClient({ 40 41 url: PUBLIC_JETSTREAM_URL, 41 - wantedCollections: ["tv.ionosphere.comment"], 42 + // Subscribe to ALL ionosphere collections from any DID — discovers 43 + // commenters, reactions, and any future record types automatically 44 + wantedCollections: [ 45 + "tv.ionosphere.comment", 46 + "tv.ionosphere.event", 47 + "tv.ionosphere.talk", 48 + "tv.ionosphere.speaker", 49 + "tv.ionosphere.concept", 50 + "tv.ionosphere.transcript", 51 + "tv.ionosphere.stream", 52 + "tv.ionosphere.streamTranscript", 53 + "tv.ionosphere.diarization", 54 + ], 42 55 getCursor, 43 56 setCursor, 44 57 onEvent: (event) => {