Compute top-N posts in a workspace
AtlassianSoftware Engineer · OnsiteLast updated
This question evaluates skills in designing scalable, low-latency analytics and aggregation systems, covering event tracking, time-windowed ranking, stream processing, storage trade-offs (OLTP vs OLAP), caching, API design, and handling late or duplicate events.
Design a feature that returns the top-N posts (e.g., Confluence pages/blog posts) in a workspace.
Requirements:
- Define what “top” means (e.g., views, likes, comments, or a weighted score).
- Support queries like: top N posts for the last 24 hours / 7 days / 30 days.
- Low latency for reads.
- Handle high write volume of events (views/likes).
Deliverables:
- Event tracking and aggregation design.
- Storage choices (OLTP vs OLAP) and schema.
- API design and caching.
- Handling late/duplicate events and backfills.
Solution walkthrough is for members
Get the full walkthrough with reference code and complexity analysis, plus Kitty Coach at 300 messages a day. Hints, the code runner and community answers stay free.