Design an extensible ticketing system
Company: Amazon
Role: Software Engineer
Category: System Design
Difficulty: hard
Interview Round: Technical Screen
Design an extensible EventTicketSystem for selling tickets to concerts, movies, and sports events. Support creating events, listing inventory, holding/reserving seats, purchasing with idempotency, and refunds. Show a class/interface design that allows adding new ticket types without modifying existing code (e.g., a factory or registration mechanism). Prices should be determined by pluggable strategies so each ticket type can have distinct pricing rules (e.g., dynamic pricing, fees, discounts). Discuss concurrency control for seat contention, persistence schema, transactions and rollback, error handling, and core REST/gRPC APIs. Provide complexity considerations, test strategy (unit/integration), and how you would evolve the system as new ticket types and pricing policies are introduced.
Quick Answer: This question evaluates software architecture and system-design competencies, covering extensibility patterns, concurrency control for high-throughput ticketing, transactional and idempotency guarantees, persistence/schema modeling, API design, and pluggable pricing strategies.