Home / Companies / Stream / Blog / Post Details
Content Deep Dive

How Do You Efficiently Fan-Out Activities to Large Numbers of Followers?

Blog post from Stream

Post Details
Company
Date Published
Author
Raymond F
Word Count
1,697
Company Posts That Month
30
Language
English
Hacker News Points
-
Summary

In 2019, Japanese billionaire Yusaku Maezawa highlighted the scalability challenges of social media platforms when his tweet offering one million yen to 100 retweeters went viral, illustrating the fan-out problem where a single action triggers a cascade of operations across a system. This fan-out issue is central to managing activity feeds, notification systems, and social timelines, as it involves distributing a single action to all relevant users, demanding significant system resources. There are two main strategies to handle this: fan-out on write, where activities are pre-distributed to followers' feeds for fast reading but can lead to inefficiencies with inactive users, and fan-out on read, which assembles feeds on demand and reduces write amplification but can increase latency. Most production systems employ a hybrid approach, combining both strategies to balance the needs of high-follower and high-frequency users, involving advanced infrastructure like user classification services and activity routers. Building such infrastructure from scratch requires significant engineering investment, though managed services like Stream's Activity Feeds offer solutions to manage the complexities of fan-out efficiently.

Trends Found in this Post

No tracked trend matches for this post yet.