Skip to main content

Queues

Queue names in APP_BULL_QUEUES:

EnumNameJobs observedAttempts / backoff
WEBHOOKwebhook_queue*8, exponential 5s. Concurrency 10
EMAILemail_queuewelcome-email, password-reset-email, tenant-invite-email, ticket-notification3, exponential 2s. Complete kept 24h/2000, fail 7d/5000
SYNCsync_queueorder (concurrency 15; also queued by MissingOrderFetchService with jobId payout-backfill:… to fetch an order a payout line named), product (2), customer (2), settlement (5)3, exponential 5s. Complete removed, fail 7d/1000
FULFILLMENTfulfillment_queuebatch-labels (concurrency 5)default retention: 3 attempts, exponential 2s
SETTLEMENTsettlement_queueupload (concurrency 5; marketplace settlement files and Amazon FBA reports, by ImportBatch.kind), gateway-sync (concurrency 2, one job per payment account), erp-push (concurrency 1, one job per accounting system)upload: default retention. gateway-sync: 2 attempts, exponential 60s, removed on complete and on fail so a manual retry with the same jobId is not ignored. erp-push: 1 attempt, removed on complete and fail, jobId per system per day
ADDRESS_VALIDATIONaddress_validation_queuevalidate-pending-order (concurrency 5)default retention
INVENTORYinventory_publish_queueflush-channel:SHOPIFY, WOOCOMMERCE, FLIPKART, AMAZON, DEFAULT, channel-feed-poll, reconcile-channel-batchINVENTORY_QUEUE_DEFAULT_JOB_OPTIONS
STOCK_UPLOADstock_upload_queuestock-bulk-uploaddefault retention
SHIPMENT_TRACKINGshipment_tracking_queuepoll-shipment-tracking, refresh-shipment-trackingdefault retention
WEBHOOK_HEALTHwebhook_health_queuewebhook_healthregistered without the shared retention constant

Not in the enum: whatsapp-catalog-provisioning / job provision-catalog.

Bull retries when the processor throws. A processor that catches an error and returns normally does not retry. That pattern was not exhaustively listed. Hunt for it in courier and inventory processors before you assume a failure is retried.

Bull jobId dedupe was not verified on each queue.add. Without a job id, Bull accepts duplicates.

Terminal job failure is reported to Sentry from BaseQueueProcessor when a Sentry client exists. Non-terminal failures are warnings.

Bull Board: /admin/queues, basic auth. The board registration that was read features webhook, sync, inventory, stock upload, and webhook health. It does not list every queue in the enum.

Schedulers​

These run on the scheduler process unless noted.

ClassCronEffect
SyncJobScheduler* * * * *Enqueue due channel sync. Offsets inside the minute: order 0, product 3, customer 7, settlement 11
AddressValidationScheduler* * * * *Pending address checks
ShipmentExceptionScheduler* * * * *Exception sweep. Method body was not fully read
InventoryReconciliationScheduler0 * * * * and */2 * * * *Inventory reconcile. The two crons were not mapped to method names
OrderItemReconciliationScheduler*/10 * * * *Order line reconcile
ChannelFeedPollReaperScheduler*/10 * * * *Requeue stuck inventory feed polls
ShipmentTrackingScheduler0 */3 * * *Tracking poll
SettlementReconciliationScheduler0 2 * * *Retry payout lines that found no order (20 h spacing, parked after 10), open receivables for billable orders the listener missed, recompute overdue ones, and open cases for unpaid FBA reimbursements. See Settlements
CodRemittanceScheduler0 4 * * *Pull courier COD remittance statements for connected iThink accounts, last 3 days
GatewaySettlementScheduler0 5 * * *Queue gateway-sync for every ACTIVE API payment account of an active tenant, last 10 days. See Payment gateway settlements
ErpAutoPushScheduler0 6 * * *Queue erp-push for every ACTIVE accounting system with auto-push on (not file export). See Accounting systems
WebhookHealthCheckSchedulerWEBHOOK_HEALTH_CHECK_CRONEnqueue health jobs
ConnectionTokenExpiryScheduler30 3 * * *For CONNECTED OAuth connections whose config records refreshTokenExpiresAt (Flipkart, and Amazon at authorization + 365 days): set lastHealthCheckError 21 days before expiry, and status EXPIRED once it passes
MidNightScheduleWorker0 0 * * *Logs only. No business work in the method body
PartitionMaintenanceServicedaily 02:00 and weeklyRuns on the worker, not the scheduler. Covers PayoutLine, JournalLine (kept forever) and ImportRawRow (13 months) besides the older partitioned tables
OutboxDispatcherService1s poll, purge 03:00Worker only

TrackedCron reports cron failures to Sentry. Schedulers let a failed run propagate to it; a per-item failure inside a run is reported with reportError and the run continues.

Sync intervals encoded as constants: product 6 hours, customer 12 hours, settlement 24 hours. Order interval is per tenant. A comment says production tenants use 5 minutes. That value is not the scheduler constant.

Channel sync jobs are skipped when the tenant or subscription is inactive, and when the channel type has no handler.

Settlement sync is additionally skipped when the channel's settlement service implements supportsScheduledSync(channelId) and it returns false. Meesho returns true only for channels configured with useSandbox. A check that throws is logged as a warning and the sync is skipped (sync-job.scheduler.ts).