YOUR BRIEF
What to work through
Work through photo storage with dedup as a spoken system design interview. Start by clarifying the scope, sketch a working design and explain the trade-offs behind your choices.
- Upload photos from phones and computers
- Browse a library and view photos at different sizes
- Delete photos
- Store byte-identical uploads only once, matched by SHA-256
BEFORE YOU START
Constraints to discuss
- Content is never deleted while any photo record still points to it
- A matching hash is verified on the server, never trusted from the client
- Two identical uploads at the same moment store the bytes once
- A deleted photo stops being viewable by its owner at once
Need a starting point?
Watch for these common gaps as you prepare:
- One table for bytes and ownership, so a delete removes another user’s photo
- Trusting a client-computed hash
- Deleting bytes the moment a count reaches zero, racing a new upload
- No answer for two identical uploads at the same moment
- Calling a resized copy a duplicate: SHA-256 matches only identical bytes
Why this question is in the collection
These sources connect the problem to company interview reports or preparation guides. They do not guarantee what a company will ask you.