Design News Feed System (Part 1)
If you have followed our previous posts on system design interview questions, you might be surprised at how common news feed system is.
No matter whether you are building Twitter, Instagram or Facebook, you will need some sort of news feed systems to display updates from follows/friends.
In fact, there are a bunch of interesting details about news feed like how to rank feeds, how to optimize publishing etc.. So in this post, I’ll cover this popular question – design news feed system.
How to Design Twitter (Part 1)
From last week’s survey, most of our subscribers want to know more about system design interview.
It’s hard to provide tips without any example, that’s why in this post I’ll use a very popular system design question to show you how to solve it.
It’s also worth to note that system design interview question can be extremely open-ended, thus there’s no such thing as a standard answer. Even for the same question, you’ll have a totally different discussion with different interviewers for sure.
System Design Interview Questions
Design a Garbage Collection System (Part I)
Our system design interview series gets a lot of feedback in the past couple of months. I’m glad to know that our readers find it helpful.
One advice I always give is that don’t take these articles as standard answers. System design interview questions are usually open-ended and it’s all about analysis and communication. Any point in the discussion can go deeper based on interviewers’ preferences.
This week, the question is slightly different as it’s a little low-level but at the same times quite useful – garbage collection system.
Consistent hashing is a simple yet powerful solution to a popular problem: how to locate a server in a distributed environment to store or get a value identified by a key, while handle server failures and network change?
A simple method is number the servers from 0 to N – 1. To store or retrieve a value V, we can use Hash(V) % N to get the id of the server.
However, this method does not work well when 1) some servers failed in the network (e.g, N changes) or 2) new machines are added to the server.
How to design a tinyurl service is one of the most popular interview questions. It is often asked in the third or fourth round as the big data design interview question. To master tinyurl design, you need to be familiar with Base Conversion of Numbers, and Consistent Hash algorithm.
So what is tinyutl service? It is a URL service that can provide a map between a shorter and unique url to a long URL provided by a user.
For instance, “http://wp.me/p7Eshi-o3” is the tiny url for the current page. Typically,