אינטגרציות ו־API
הרצת workers
הרצת worker מתמשך, בדיקת smoke וגבולות תורי העבודה.
BullMQ workers are intentionally not started inside ordinary Next.js/Vercel request functions.
The Web application may enqueue jobs once REDIS_URL is configured. A dedicated worker runtime must host long-lived BullMQ Workers using the helpers in lib/jobs/worker.ts.
Initial queue contract:
provider-sync— provider stations/status/tariffs/transactions sync.webhook-reconciliation— asynchronous webhook verification/reconciliation.billing-reconciliation— non-interactive billing reconciliation work.
Rules:
- Supabase remains the source of truth.
- Redis carries cache entries and queue state only.
- Job payloads must contain identifiers, never provider API secrets or payment credentials.
- Every externally sourced event must use an idempotent provider event ID.
- Worker secrets belong in the worker runtime secret store.
- Production REDIS_URL must use
rediss://. - Durabull becomes the operations console after the Redis connection is visible there.