Cloud Message Queues
debt(d7/e5/b7/t7)
Closest to 'only careful code review or runtime testing' (d7). The detection_hints note 'automated: no' and the listed tools (aws-sqs, laravel-horizon, datadog) are monitoring/observability tools rather than static analysis that catches misconfigurations at write-time. Issues like a visibility timeout shorter than processing time, missing DLQ, or wrong queue type only surface under load or through runtime observation — not at compile or lint time.
Closest to 'touches multiple files / significant refactor in one component' (e5). The quick_fix involves changing queue type (Standard → FIFO), adjusting visibility timeouts, and adding DLQ configuration. While individual settings are simple, correcting an order-sensitive workflow that was built against SQS Standard requires reviewing and potentially restructuring job dispatch logic, consumer code, and infrastructure configuration across multiple files/layers.
Closest to 'strong gravitational pull' (d7). Cloud queues apply to both web and queue-worker contexts and sit at the architectural seam between producers and consumers. The choice of queue type (Standard vs FIFO), DLQ strategy, and visibility timeout shapes every background job, retry policy, and failure-handling decision across the system. Every future feature that offloads async work is constrained by these foundational choices.
Closest to 'serious trap — contradicts how a similar concept works elsewhere' (t7). The canonical misconception is explicit: 'SQS Standard guarantees FIFO — it provides best-effort ordering only.' Developers familiar with traditional message brokers or even named 'queue' semantics reasonably assume FIFO ordering, but SQS Standard deliberately does not guarantee it. This contradicts the everyday mental model of a queue data structure, making it a serious and well-documented trap.
Also Known As
TL;DR
Explanation
SQS Standard: at-least-once, best-effort order. SQS FIFO: exactly-once, ordered. Pub/Sub: near-unlimited throughput. Always configure dead-letter queue. Use long polling (WaitTimeSeconds=20) to reduce empty API calls.
Common Misconception
Why It Matters
Common Mistakes
- SQS Standard for order-sensitive workflows
- No dead-letter queue
- Short polling instead of WaitTimeSeconds=20
- Visibility timeout shorter than processing time
Code Examples
$sqs->receiveMessage(['QueueUrl'=>$q]); // Short polls — 1440 empty calls/day
$sqs->receiveMessage(['QueueUrl'=>$q,'MaxNumberOfMessages'=>10,'WaitTimeSeconds'=>20,'VisibilityTimeout'=>300]);