---
title: "Captured: ChatGPT — System Design Q&A"
url: https://mdfy.app/ycd28WPg
updated: 2026-05-05T02:21:31.009Z
source: "mdfy.app"
---
# Captured: ChatGPT — System Design Q&A

> **You**: For a real-time notification service handling 50M DAU,
> what's the right queue strategy?

> **GPT**: Three-tier:
> 1. **Ingestion queue** (Kafka): all events arrive here, partitioned
>    by user_id for ordering.
> 2. **Routing queue** (Redis Streams): per-channel sub-queues for
>    push, email, SMS, in-app.
> 3. **Delivery queue** (SQS): per-region with FIFO for high-stakes
>    notifications.
>
> Kafka handles back-pressure. Redis Streams handles fanout. SQS
> handles per-provider retry semantics.

> **You**: How do you guarantee no duplicate notifications?

> **GPT**: Dedupe at the routing tier. Use a deterministic hash of
> (user_id, event_id, channel). Redis SET NX with TTL = 24h. If the
> SET fails, skip. Edge case: provider retries that bypass your
> routing — those need provider-side idempotency keys too.
