Skip to content
Katabench
Try free

Publish the First Post

Easy About 20 min Free with an account

A social prototype writes posts from the browser and hides follows in a JSON column. Put a trusted Post API in charge, with content in the Post Store and relationships in their own Social Graph.

The brief

The social app's first version writes posts from browser code directly into a table, and it keeps each user's follow list as a JSON array stuffed into the same table. A modified client can impersonate another author, follow someone on their behalf, and set impossible visibility values; and because follows hide inside post rows, nothing can ever query "who follows Ana" without scanning everything.

A social network has two primitive writes, and they are different data. A post is content: authored once, read by many. A follow is a relationship: an edge between two people, written on its own schedule, and the thing every future feature (the home feed above all) will need to query by both ends. Give each its own store, and one API ownership of both.

Drag components from the palette, wire the interactions, and Check the design.

Goals

  • Place an API gateway and Post API between the client and all storage.
  • Publishing: Social Client → API Gateway → Post API → Post Store.
  • Following: the same path into the Social Graph, a separate store for the relationship edges.
  • Remove every direct client-to-store line; identity and relationships are integrity facts.

The topology is deliberately bounded. Choose the responsibility and interaction pattern, not a cloud vendor or product SKU.

How it is graded

You build the design on a canvas, and Katabench checks the topology against the challenge's design rules.

System Design Studio →

What it practices

Stateless app tier
Route clients through a trusted, horizontally scaled app tier behind a load balancer.

Related katas