How to estimate data requirements
Traffic Estimates

Hint #3: Build upon established numbers.

When thinking about expected traffic, this is how you should be thinking:

OK, we have 500m users per month — how many is this per day? Of course, it’s not 500M / 30 days. How are these users geographically spaced? Are they all over the world are they all on the same continent? When do they use the app? Are they all using it at the same time, at 5:30 PM when they come from work?

Since we already went to the trouble of figuring out the 1.5 billion image uploads per day — this is the number we should lean on.

For simplicity, let’s say these uploads will be perfectly distributed over the whole day. This gives us:

uploads = (1.5 * e9 images / day) / ( 24h ∗ 60m ∗ 60s )

≅ 17 000 images / s

17K images are uploaded every second, but each of these images is also viewed v times. This is a photo-sharing app, so for every upload, there is going to be v viewings. Let's say that on average every image gets viewed ten times. This means 170 000 requests per second:

requests = 17 000 images / s ∗ 10 req / image

= 170 K req / s

170 K req / s ∗ 1 MB / req = 170 GB / s

This means that our servers need to serve 170 GB/s.

Servers are limited by two things: the number of concurrent connections and the bandwidth.

What’s a reasonable number of concurrent connections for a server? I’ve no idea. It depends at least on the server’s spec and the kind of processing we will be doing for each request. The only way to answer this would be to look at the statistics of some actual servers, of which there seem to be very few on the internet.

How are we supposed to continue with no data from here on? I don’t know. Can one server deliver 1Gb of data per second (that is 8,000 000 Kb/s)? I don’t know. Maybe it is closer to 0.1 Gb/s, maybe it is 0.01 Gb/s.

Everything up to here was speculation, but everything from here on would be pure imagination! I presume there are some specialists somewhere, who deal with these numbers all the time. Better ask them!
['Ines Panker']
['Software Development', 'Software Architecture', 'Interview Questions', 'Traffic Estimation']