You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
v0.8.3 — Production Worker & Expiration Reminder (2026-08-19)
Added
Production Worker watchdog (Phase 11D): scripts/worker-watchdog.sh — single-instance hourly scheduler (flock-guarded, self-contained, no pnpm-on-PATH dependency). Each tick runs the worker exactly once (./node_modules/.bin/tsx --conditions=react-server scripts/worker.ts --limit 50); a non-zero tick exit is logged and the loop continues; TERM/INT exit cleanly.
Hourly expiration reminder processing: evaluateExpirationReminders() emits one deduplicated expiration_reminder event per domain once the reminder day arrives.
Expiration reminder → delivery pipeline (Phase 11D): insertEventsAndGenerateDeliveries creates the event and its deliveries together; CAS claim (UPDATE … WHERE status='pending') guarantees at most one event, one delivery and one sender invocation per reminder per day.
Migration journal repair (Phase 11E): 0007_manual_expiration is now registered in the drizzle journal (_journal.jsonidx: 7, when: 1787063220000), 0007_snapshot.json generated (13 tables incl. expiration_reminders), and the production __drizzle_migrations table registered with the migration's sha256 hash. A fresh 0000 → 0007 migration was verified end-to-end; the migration itself was not re-executed on any database.
Fixed
Worker crash under react-server / production conditions (Phase 11D): senders/factory.ts imported senders through the @/lib/domains barrel, which pulled in next/cache and crashed under production conditions. The factory now imports from the repository module directly.
Expiration reminder events never produced deliveries (Phase 11D): events and deliveries are now created together via insertEventsAndGenerateDeliveries.
Changed
Version bumped from v0.8.2 → v0.8.3; tsx@4.23.12 added as a development dependency.
src/db/migrations/meta/_journal.json now has 8 entries (0000–0007); 0007_snapshot.json added.
Notes
The worker is enabled in production (hourly watchdog). Real notification delivery was not exercised as part of this release; the real-notification safety gate remains a separate approved exercise.