Skip to content

subscriptions

Kadyapam edited this page May 29, 2026 · 2 revisions

Firestore subscriptions (removed in v2.12.0)

Removed in v2.12.0 (Round 03 of noetl/ai-meta#23). The gateway no longer carries a Firestore subscription subsystem. The travel SPA reads calendar data via the travel/playbooks/catalog/calendar/list read playbook and listens for calendar.event.touched SSE frames — see SSE events and the travel wiki / gateway integration.


What was here (historical reference)

POST /api/subscriptions/firestore let an authenticated client subscribe to live Firestore updates server-side without holding a Firestore SDK in the browser. The gateway ran the watch via a Python sidecar (scripts/firestore_listener.py) and pushed changes to the client over the SSE channel as subscription/event frames.

This was added in v2.11.0 as the companion to travel#50 (removing firebase/firestore from the SPA bundle), and removed in v2.12.0 once Round 02 of the Firestore-removal work cut the travel SPA over to a playbook-mediated transport (calendarSubscription.ts).

Round 02 already removed the only consumer (gatewaySubscriptions.ts in the travel SPA). Round 03 removed the dead server-side code:

  • src/firestore_subscriptions.rs (412 lines) — deleted.
  • scripts/firestore_listener.py — deleted.
  • main.rs mod/use declarations, route registrations, and manager construction — removed.
  • sse.rs FirestoreSubscriptionManager import + state field — removed.
  • config/gateway_config.rs FirestoreConfig struct + ServerConfig field + Default impl + GATEWAY_FIRESTORE_* env handling — removed.

The subscription/event SSE frame type is no longer emitted. The subscriptions: false capability flag remains in the SSE init frame for protocol compatibility.

Migration

If you extended the gateway or a fork for Firestore subscriptions, the replacement pattern is:

  1. Write a read playbook that queries Firestore (or any store) and returns the data under a display_events key.
  2. In the SPA, call executePlaybook(path, workload) on mount for the initial load.
  3. Listen for calendar.event.touched (or another domain-specific event type) on the playbook/state SSE channel to trigger re-reads on writes.

This is the pattern the travel SPA uses — see travel wiki / gateway integration for the full worked example.

Related

Clone this wiki locally