Hacker News new | ask | show | jobs
by canardlaquay 3129 days ago
I've been working on that video platform as a hobby - a twitch clone, or more accurately a clone of Mixer (formerly beam.pro). I've abandoned it, even though it probably still works at a low scale.

I was still a student at the time (2 years ago), that definitely was a big issue for me so I tried to build my own CDN. There are many things that pushed me to abandon the idea: pricing, lack of time, lack of knowledge about DevOps and/or lack of tools. I've learned a lot since then.

I had a few problems with managing the total available bandwidth as well as the monthly data cap (1TB on the cheapest DigitalOcean droplet), this could be resolved if you already have the servers running, managed and updated, but it won't resolve the scaling problem unless you possess a datacenter.

It would be pretty simple to setup a CDN with that solved: - Have your ingest servers make the files available somehow (scalable/shared filesystem? NoSQL? or just a webservice?) - Make your viewers ping your cache servers (Varnish), and if the file isn't cached, then fetch it from the ingest server. - Put a layer 4 load-balancer (also known as Direct Server Return) in front of those cache servers, and adjust the weight of each cache server since the network throughput will probably not be the same for all of the servers. - Automatize all of this so the cache servers know about the new ingest servers, same thing for the load-balancer about the new cache servers. Done!

Once all of this is set up, this is just a matter of starting new servers and doing maintenance on the other ones while keeping everything available. After that, you can focus on the second point: using the ads the finance your service and keep it running.

"I wanted to build a video platform, not a CDN! And now, I have build an advertising platform?" - I must have told myself that a thousand times back then!

1 comments

This is a really amazing insight and something that gets glossed over a lot in the "we need an open competitor to YouTube" comments. $85 for 60,000 minutes watched, thats about thats a cost of $0.001 per minute (or 8.5 cents per hour watched).

For comparison a fairly large YouTube channel makes $0.0005 per minute (or 3 cents per hour watched) just on YouTube generated revenue. Granted YouTube is taking a 50% cut (so they are really generating 6 cents per hour), but in your naive example, even if you had a completely mature programmatic ad platform, you would still be losing 2.5cents per hour streamed.

Video distribution is costly and is likely what is preventing other players from entering into the space.