← Roblox Interview InsightsSoftware Engineer

Roblox·Software Engineer·Onsite - System Design / Architecture·Senior

SeniorPrefer not to say
Jun 2026

Summary

System design round at Roblox for a software engineering role, focused entirely on building a Likes system from scratch. The question had a lot of surface area and pushed into some genuinely tricky territory around consistency and scale.

Questions Asked (1)

Q1

Design a Likes system that supports liking/unliking items, checking if a user liked something, listing all items a user has liked (paginated), and fetching the total like count for an item. Focus on scalability and data schema.

System DesignData ModelingTechnical Trade-offs
Author's notes

This looked simple at first and then just kept expanding.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by clarifying functional and non-functional requirements, then propose a scalable data model using a wide-column store like Cassandra for likes and a distributed counter for like counts. Discuss trade-offs between consistency and availability, and outline how to handle pagination and hot partitions.

Pro tip: Mention that like counts can be eventually consistent and use a write-optimized counter service like Redis with periodic persistence to handle high write throughput. Also, consider sharding by item ID to distribute load evenly.

1. Clarify Requirements and Scale

Ask about expected read/write ratio, latency requirements, and consistency needs. Estimate scale (e.g., millions of likes per second) to inform design choices.

2. Design Data Schema

Propose tables: one for user likes (user_id, item_id, timestamp) and one for item likes (item_id, user_id, timestamp) to support efficient queries. Use a distributed database like Cassandra for scalability.

3. Handle Like Counts

Use a separate counter service (e.g., Redis) to maintain like counts per item, with asynchronous updates to a persistent store. Discuss trade-offs of strong vs. eventual consistency.

4. Implement Pagination and Queries

For listing user likes, use time-based pagination with a clustering key on timestamp. For checking if a user liked an item, use a composite key lookup.

5. Address Scalability and Trade-offs

Discuss sharding strategies (e.g., by item_id or user_id), caching, and handling hot items. Mention trade-offs between consistency, latency, and cost.

Key Points to Mention

  • Use of a wide-column store like Cassandra for its scalability and ability to handle high write throughput.
  • Denormalization: maintaining two tables (user_likes and item_likes) to support both query patterns efficiently.
  • Counter service (e.g., Redis) for fast like count retrieval, with eventual consistency to the database.
  • Pagination using time-based clustering keys and handling of large result sets.
  • Sharding strategies to avoid hot partitions, such as sharding by item_id for item likes and by user_id for user likes.
  • Trade-offs between consistency and availability, and how to handle idempotency for like/unlike operations.

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.