InterviewLegend

Design a Stock Price Alert System

Alex Chen48 min readUpdated 548 real interview reports

A stock price alert system watches a live stream of prices and tells users when a stock they care about does something they asked to hear about. The user picks a ticker and a rule. The system checks each new price against the rules on that ticker and sends a push notification when one fires. Uber isn't a broker, but this is one of the prompts candidates report most often from Uber's high-level design round in recent years. It shows up mostly in L4 (SDE-2) loops, often as the Bar Raiser's design round in India, and also at L5a and L5b. The product is small. The numbers behind it are what make it hard: tens of millions of standing rules checked against tens of thousands of price updates a second, and every alert delivered once even when part of the pipeline fails.

The Uber angle
Candidates who get this prompt at Uber describe interviewers who skip the basic version and go straight to the hard parts. Expect questions along the lines of "how do you check a million rules on every tick without hitting the database?", "how do you shard when Apple ticks far more often than a small cap?", "how do you make sure nobody gets the same alert twice?" and "what happens if the publish to Kafka fails?". So sketch the simple pipeline in five minutes or so and spend the rest on rule evaluation and delivery. Kafka and Flink are both part of Uber's own streaming stack, and Uber runs one of the largest Kafka deployments around, so both are natural picks to name here.

UberPremium lesson · System design round

The Uber design, worked end to end.

  1. The API and data modelSystem design
  2. The design, drawn out2 diagrams
  3. 5 deep divesWith the tradeoffs
Get the Uber questions

$49 a year · all 100 companies · cancel anytime

From 548 Uber reports, forum threads behind logins and write-ups in Chinese.

Had your Uber interview?Tell us what they asked. Reviewed before it goes in, never with your name.
Uber interview guide

Know what Uber asks before you walk in.

30 coding · 4 system design · 21 behavioral questions

Get Premium$49 a year · Cancel anytime
Or start freeNo card.

Get their questions first.

InterviewLegend is independent and not affiliated with or endorsed by any company it covers.