← Netflix Interview Insights

Netflix·Software Engineer·Onsite - System Design / Architecture·Senior

Senior
May 2026

Summary

Netflix system design round, one big question about an ad platform data model. Took up the whole session and went pretty deep into schema design, indexing, and the different flows. Felt okay about it but there were definitely gaps I noticed only after.

Questions Asked (1)

Q1

Design a logical data model for an advertising platform, covering advertisers, campaigns, creatives, targeting, user identifiers, and delivery logs. Explain key entity relationships, how the schema supports the creation, serving, and tracking flows, and what indexing or partitioning decisions you'd make at scale.

Data ModelingSystem DesignTechnical Trade-offs
Author's notes

This is a bigger question than it looks.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying requirements and scale, then sketch a high-level entity-relationship diagram covering the core entities and their relationships. Walk through the write path (campaign creation) and read path (ad serving and tracking), and finally discuss indexing and partitioning strategies for scale.

Pro tip: Emphasize how the model supports Netflix's unique advertising needs, such as frequency capping and targeting based on viewing behavior, and discuss trade-offs between consistency and latency in a high-volume environment.

1. Clarify Requirements and Scale

Ask about expected QPS, data volume, and specific features like real-time bidding or frequency capping. This ensures the design meets actual needs and shows you think before coding.

2. Identify Core Entities and Relationships

Define entities: Advertiser, Campaign, Creative, TargetingRule, UserIdentifier, DeliveryLog. Describe relationships: Advertiser has many Campaigns, Campaign has many Creatives and TargetingRules, DeliveryLog links UserIdentifier to Creative.

3. Design Schema for Write and Read Paths

For write path (campaign creation), use normalized tables for consistency. For read path (ad serving), consider denormalized views or caching for low-latency lookups. Explain how tracking events are written to DeliveryLog.

4. Address Scale with Indexing and Partitioning

Propose indexes on foreign keys and frequently filtered columns (e.g., campaign status, targeting attributes). Partition DeliveryLog by time (e.g., daily) and consider sharding by user_id or campaign_id for horizontal scaling.

5. Discuss Trade-offs and Optimizations

Mention trade-offs like normalization vs. denormalization, consistency vs. latency, and how to handle high-cardinality targeting attributes. Suggest using a columnar store for analytics and a KV store for real-time serving.

Key Points to Mention

  • Entity relationships: one-to-many between Advertiser and Campaign, Campaign and Creative, etc.
  • Targeting rules as flexible key-value pairs or JSON to support diverse criteria.
  • User identifiers: hashed emails, device IDs, or Netflix profile IDs, with privacy considerations.
  • Delivery logs: append-only, time-series data for tracking impressions, clicks, and conversions.
  • Indexing: composite indexes on (campaign_id, timestamp) for efficient log retrieval.
  • Partitioning: time-based partitioning for logs, and sharding by user_id for even distribution.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.