Learning/AWS SQS/29 — Hands-on Labs/Lab 12 — SNS → SQS fanout
Advanced outline
This chapter is an outline. The curriculum, learning objectives and structure are settled; the prose, diagrams and code are still being written. What is below is the plan for the chapter, not the chapter.

Lab 12 — SNS → SQS fanout

Goal

One publish, two independent queues, and a filter policy that routes without producer changes.

Setup

To be written — CLI commands and an IaC equivalent for every resource, all prefixed sqs-course-.

Steps

  1. Create a topic and two queues
  2. Subscribe both; forget the queue policy first and observe the silent non-delivery
  3. Add the queue policy with aws:SourceArn and retry
  4. Publish once; confirm both queues received a copy
  5. Enable raw message delivery on one and compare the payloads
  6. Add a filter policy to one subscription; publish messages that match and do not
  7. Break one consumer; confirm the other is unaffected

What you should observe

  • Without the queue policy, delivery fails with no error on the publish side
  • The default envelope wraps your payload; raw delivery does not
  • Filtered-out messages are never delivered, so never billed

Why it happened

To be written — ties each observation back to the mechanism in 20 — SNS + SQS Fanout.

Experiments to try

To be written — deliberate variations that change the outcome.

Teardown

To be written — every resource created above, in dependency order.


Back to: 29 — Hands-on Labs