<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Vikram Santhosh</title>
    <description>The latest articles on DEV Community by Vikram Santhosh (@vikram_santhosh).</description>
    <link>https://dev.to/vikram_santhosh</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3147841%2F0e8b7fcf-61bb-41d7-8bc5-bc72cc298b2f.png</url>
      <title>DEV Community: Vikram Santhosh</title>
      <link>https://dev.to/vikram_santhosh</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/vikram_santhosh"/>
    <language>en</language>
    <item>
      <title>News Feed System Design Interview: Fan-Out on Write vs. Read</title>
      <dc:creator>Vikram Santhosh</dc:creator>
      <pubDate>Sat, 28 Nov 2026 01:02:55 +0000</pubDate>
      <link>https://dev.to/vikram_santhosh/one-post-20-million-followers-would-you-still-push-it-4oab</link>
      <guid>https://dev.to/vikram_santhosh/one-post-20-million-followers-would-you-still-push-it-4oab</guid>
      <description>&lt;p&gt;A post goes out to 20 million followers. Your feed store has 100,000 writes per second to spare. In 30 seconds you can reach &lt;strong&gt;15%&lt;/strong&gt; of those followers. If the interviewer wants 99%, which part of your design would you change?&lt;/p&gt;

&lt;p&gt;&lt;a href="https://vikram-santhosh.github.io/news-feed-fanout-calculator/" rel="noopener noreferrer"&gt;Try the news feed fan-out calculator&lt;/a&gt; with a different audience or deadline. If you’d rather see it on the whiteboard, &lt;a href="https://www.udemy.com/course/staff-system-design-interview-part-1-feeds-chat-real-time/?couponCode=STAFF-BLACK-FRIDAY" rel="noopener noreferrer"&gt;watch me draw the push and pull paths in my news feed lesson&lt;/a&gt;. It’s part of my Udemy course for senior and staff interviews. My instructor coupon is free for the first 100 enrollments and expires Dec 28th.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“Maya has 20 million followers and just posted. Are you going to write her post into all 20 million feeds?”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;My first question would be how late the post is allowed to be. If a follower opens the app 30 seconds from now, is it OK for them to miss it? How about three minutes from now? I'd make a different call depending on the answer.&lt;/p&gt;

&lt;p&gt;Suppose the interviewer gives you 30 seconds to reach 99% of Maya's followers. You've already drawn a worker that copies a post ID into each follower's feed. Keep that drawing for a minute. How far does the worker actually get?&lt;/p&gt;

&lt;p&gt;Say the feed store has 100,000 writes per second to spare once ordinary traffic is taken care of. In half a minute you can update 3 million feeds. The other 16.8 million entries due by then are still sitting in the queue. Even if nobody else posts, the last of those entries lands at &lt;strong&gt;3 minutes and 18 seconds&lt;/strong&gt;.&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;“I'd keep the worker for most authors. For Maya I'd write the post once, to her own timeline. When one of her followers opens the app, we can fetch Maya's latest posts alongside the feed we've already prepared.”&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;I'd draw that second lookup on the board. It's easy to say “hybrid fan-out” and leave the impression that we've solved the expensive part. Now give Alice, the reader, 200 high-profile accounts to follow. When she opens the app, how many of those timelines are we willing to wait for?&lt;/p&gt;

&lt;p&gt;That's where I'd spend the next few minutes of a staff interview. I'd want to know how common Alice's case is among people who actually open the app. I'd also want to test what she sees when one timeline is slow. If we give up on that lookup after 50 milliseconds, our latency graph might look great while Maya's post keeps disappearing from Alice's feed.&lt;/p&gt;

&lt;p&gt;If you're doing a mock this week, give your partner the opening question and keep the 30-second requirement to yourself until they ask. I’m curious what deadline they assumed when they first heard “20 million.”&lt;/p&gt;

</description>
      <category>systemdesign</category>
      <category>interview</category>
    </item>
  </channel>
</rss>
