Skip to content

Internal Architecture

We believe in transparency. Here’s how Seamlr processes integration events internally.

Seamlr uses PostgreSQL Message Queue (PGMQ) for reliable event processing:

  • At-least-once delivery: Messages are guaranteed to be processed
  • Visibility timeout: Messages become invisible during processing
  • Automatic retry: Failed messages return to queue after timeout
  • Durability: Messages persist in PostgreSQL
AttemptAction
1-4Process message, retry on failure
5+Move to Dead Letter Queue (DLQ)

Messages in the DLQ require manual investigation and are not automatically retried.

OperationTypical Time
Webhook acknowledgment< 500ms
Shift processing< 30 seconds
Candidate sync< 10 seconds
DLQ escalationAfter 4 failed attempts
HTTP StatusMeaning
200Webhook received and queued
400Invalid payload schema
500Internal error (will not retry automatically)
  • Transient failures (5xx from provider API): Trigger automatic retries
  • Permanent failures (4xx from provider API): Logged, may require manual resolution

When Seamlr updates or deletes a shift in the provider system, the provider typically sends a webhook back to Seamlr. To prevent infinite loops:

  1. Before calling provider API: Seamlr records a “pending operation”
  2. Webhook arrives: Seamlr checks for matching pending operation
  3. If match found: Skip processing (this is our own change echoing back)
  4. Pending operations expire: After 5 minutes, records are automatically cleaned up

This ensures Seamlr only processes genuine external changes.