Skip to content

30 câu hỏi phỏng vấn System Design dành cho Senior / Lead Engineer

Phần A – Khả Năng Thiết Tế & Suy Nghĩ Kiến Trúc (Core System Design)

1. Bạn thiết kế URL Shortener như Bit.ly thế nào?

Thang tải 1B URLs, 100k RPS đọc.

2. Thiết kế Messaging system kiểu WhatsApp / Zalo:

Guarantee delivery, read receipts, presence tracking.

3. Thiết kế Realtime Notification (web/mobile push).

10M users, fan-out model?

4. Design Rate Limiter cho API gateway.

Token bucket vs leaky bucket vs sliding window – chọn gì?

5. Thiết kế hệ thống ChatGPT logging / tracing & search logs 30 ngày.

storage, indexing, retention.

6. Thiết kế Distributed Cache with consistency.

cache invalidation, stampede prevention.

7. Thiết kế Payment Gateway / OTP Authentication.

idempotent, retry, fraud detection.

8. Design Job scheduling (cron distributed).

guarantee execution once, failure retry.

9. Thiết kế E-Commerce Flash Sale (Shopee / Tiki) không oversell.

10. Thiết kế News Feed ranking như Facebook / TikTok.

push vs pull, fan-in vs fan-out.


Phần B – Khả Năng Trade-Off, Consistency & CAP

11. Khi nào bạn chọn SQL vs NoSQL cho hệ thống large-scale? ví dụ.

12. Sharding vs Partitioning khác nhau thế nào? khi nào cần?

13. Eventual consistency – khi nào chấp nhận? VD cho social feed.

14. Làm sao đảm bảo idempotency cho API thanh toán?

15. CAP theorem trade-off thế nào khi storage distributed?

16. How do you design DB schema migration safely in production?

zero downtime / backward compatibility.


Phần C – High Availability, Fault Tolerance & Failure Recovery

17. Thiết kế hệ thống resilient nếu Redis cluster fail?

18. Làm sao ensure message không mất khi queue consumer crashed?

19. Circuit breaker, retry policy & backoff – dùng khi nào?

20. Thiết kế Saga cho multi-service transaction?


Phần D – Scalability

21. Hệ thống cần scale 10x request – bạn bắt đầu từ đâu?

22. Stateless vs Stateful – trade-off và migration strategy?

23. Làm sao scale database reads without write bottleneck?

24. Caching strategy nào cho hệ thống có dữ liệu write-heavy?


Phần E – Data Modeling & Storage Design

25. Làm sao thiết kế storage cho log analytics (ELK, Clickhouse)?

Hot/cold tier, retention, indexing.

26. Chọn storage cho metrics time-series 100M datapoints/hr?

TSDB vs columnar DB.

27. Thiết kế multi-tenant database (schema-per-tenant? shared?).

isolation, noisy-neighbor.


Phần F – API Design, Versioning & Platform

28. API Versioning strategy? backward compatibility? feature toggle?

29. Request tracing / distributed tracing – bạn thiết kế thế nào?

trace ID, correlation ID, sampling.

30. Thiết kế Rate Limiting cho public API với pricing plan?

per-user, per-IP, per-plan, quota reset, burst.


Bonus: Cách interviewer Senior kỳ vọng bạn trả lời

✔ Bước 1 – làm rõ yêu cầu

Scale? latency? consistency? user behavior?

✔ Bước 2 – estimate sizing

RPS, peak factor, storage volume.

✔ Bước 3 – high level architecture

Client → Gateway → Service → DB + Cache + Queue + Analytics

✔ Bước 4 – deep dive nơi thú vị (cache, queue, feed, payment…)

✔ Bước 5 – xử lý failures

retry, circuit breaker, idempotency, message reprocess.

✔ Bước 6 – mở rộng & evolution theo scale tăng.

Published inAll

Be First to Comment

Leave a Reply

Your email address will not be published. Required fields are marked *