davidgatti/How-to-Stream-Movies-using-NodeJS

Is it scalable solution?

Dannybrown2710 opened this issue · 5 comments

This is a question, is there any way to make it scalable? What strategies can be used to make it more usable and efficient?

There so many ways it all depends on your needs. But this is just an article and not a full solution. By the way S3 supports range, so no need for a custom server, you can jsut host on S3 your files and provide the range to read:

https://docs.aws.amazon.com/AmazonS3/latest/API/API_GetObject.html#API_GetObject_RequestSyntax

Thanks for the valuable response. So, we can actually utilise s3 directly to stream video files?

it is possible, didn't look in to it. but if AWS implemented the same interface the video player expects, where the range is provided in the URL, then S3 should give back that ragne, if not you'll just need to write a bit of code that will sit between the player and S3, and pass the request from the player to S3, and get that chunk, and then send that payload back to the player. and that is it.

Oh ok, I assume it charges a ton. 20 cent per GB

I believe EC2 transfer out of the AWS network costs the same or close to it. Streaming video is not an easy thing due to money - which dose not scale well ;)