Hacker News new | ask | show | jobs
by ksarw 866 days ago
I don't think Cloudflare's free egress covers video storage and retrieval

https://community.cloudflare.com/t/can-we-serve-video-with-r...

Please correct me if I am mistaken; also R2 is not a CDN, and more like s3 in terms of delivering from the edge

No issue with your comment specifically, just wondering if you know. currently using s3+cloudfront for mp4 storage+delivery, and would like to move to something better if possible.

2 comments

Their terms say https://www.cloudflare.com/service-specific-terms-applicatio...

  Unless you are an Enterprise customer, Cloudflare offers specific Paid Services (e.g., the Developer Platform, Images, and Stream) that you must use in order to serve video and other large files via the CDN
https://www.cloudflare.com/service-specific-terms-developer-...

  The Cloudflare Developer Platform consists of the following Services: (i) Cloudflare Workers, a Service that permits developers to deploy and run encapsulated versions of their proprietary software source code (each a “Workers Script”) on Cloudflare’s edge servers; (ii) Cloudflare Pages, a JAMstack platform for frontend developers to collaborate and deploy websites; (iii) Cloudflare Queues, a managed message queuing service; (iv) Workers KV, D1, Durable Objects, Vectorize, Hyperdrive, and R2, storage offerings used to serve HTML and non-HTML content; and (v) Workers AI, a Service that allows customers to use Cloudflare’s inference infrastructure to invoke select third-party machine learning models (subject to applicable open source licenses or third-party terms of use for such models).
Based on their terms, serving video in R2 should be fine.
> Please correct me if I am mistaken; also R2 is not a CDN, and more like s3 in terms of delivering from the edge

Yes, it uses Cloudflare's edge network and caching infrastructure when you use a custom domain (really the only option because usage of the default domain is very limited). So yes, it's a CDN :-)

https://community.cloudflare.com/t/cdn-support-for-r2/514573

> currently using s3+cloudfront for mp4 storage+delivery, and would like to move to something better if possible.

What I have found is that (A) the egress costs are extreme compared to R2 (remember, R2 does charge per read/write though) but (B) storage is cheaper on S3. You should do a study on your storage and egress, but unless you are storing way more than your egress TB, it's probably a good deal.

Cloudflare also has a mechanism for transparently pulling content from an upstream S3 compatible store into R2. I think it's called Super Slurper iirc

I see, thanks for sharing!

I think given the cost advantage for s3 for storage, it seems almost better to pull from R2 into s3 for long-term storage (some inverse slurper).

It's good to hear though that R2 can singlehandedly match s3+cloudfront; that being said, video delivery is a bit different I'd imagine, even s3+cloudfront is finnicky with range requests etc.