Compute top-N posts in a workspace

Read the full interview experience this question came from →

Quick Overview

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.

Compute top-N posts in a workspace

Company: Atlassian

Role: Software Engineer

Category: System Design

Difficulty: medium

Interview Round: Onsite

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.

Overview: 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.

Read the full Atlassian Software Engineer interview experience this question came from

Community answers

Answer by freny07pethelis1996

name: Top posts in a workspace overview: "Atlassian-style design: top-N Confluence pages and blog posts in one workspace, scored from views, likes, and comments over 24h, 7d, and 30d." isProject: false Top-N posts in a workspace Atlassian-style system design. Reuse identity, the page/blog record, comment create/delete, and the access-control check. This design owns engagement events, the score, and GET top-N. It does not redesign the editor or the comment thread. Interactive board: Top posts (repo). Cursor live board: top-posts.canvas.tsx. Pattern (same as comments and the image crawler): lock decisions → size the write → one concrete workspace → APIs → schema and SQL → the read that stays fast → duplicates, late events, backfill → scale, failure, observability. The worked example is workspace ws_acme. Page Q3 roadmap is post p_4401. Incident review is p_4402. Handbook is p_4403. User u_9 is a member who can read all three. How to read this Each fact has one home. Later sections use that fact. They do not redefine it. | Section | What it owns | | --- | --- | | §0 | Locked product decisions | | §1 | Rates, store sizes, SLOs, and the worked scores | | §2 | Planes, and why Kafka, PostgreSQL, and Datadog | | §3 | The formula, the rolling windows, and a second ordering | | §4 | The HTTP contract, bots, and the two sequences | | §5 | How a record becomes a score: partitions, flush, hour close, ageing | | §6 | Tables, Redis keys, and every command. §6.7 is the command catalog | | §7
Atlassian logo
Atlassian
Jan 5, 2026
mediumSoftware EngineerOnsiteSystem Design
20
0

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.