Hacker Read top | best | new | newcomments | leaders | about | bookmarklet login

Great to see someone care about this. So many discussions lack this consideration and ultimately companies pay for it. Yes, I've seen this many times and why there are e.g. consultants that come in to "optimize" the platform.

Cost isn't the only thing to care about but performance. Functions might not run in every data center that would have a CDN PoP. The SSR vs SSG comparisons always miss the point and claim SSR is faster but that's only true if you're in a big popular city. As you expand - what about the other customers?

Also what about security - that's probably even more important. Each request for Vercel has a higher cost than the equivalent from Cloudfront. What are the safeguards e.g. rate limiting or DoS protection? For Cloudfront you'd need to account for WAF and other expenses.

You don't even need a lot of customers - just a bad actor to easily take down your hosting on Vercel. There have been plenty of blogs of startups using serverless setups getting attacked that costed them 1000s - 10000s of dollars.

Side note: bandwidth costs vary. Vercel does it with 1 price, so things may vary depending on where your users are. Cloudfront costs can go up. You may also need Cloudfront functions to do a few things.



view as:

Yes most edge products have these flaws. Cloudflare Workers do not though (at least not the ones being focused on). They run in every single data center across the world and are collocated with the CDN that you can access programmatically. I wish you all the best of luck if you try to take down the system. It’s handling an insane amount of load already. There’s also no billing for bandwidth.

You can manage DDoS and rate limiting protections although I don’t know the pricing on those (could be free - I don’t recall).

Disclaimer: work at Cloudflare


Not 100% unless you only have customers in the US. Correct me if I'm wrong but unless I pay for the business plan I may get re-routed on major ISPs in many countries. Have experienced this 1st hand.

For many workloads Cloudflare can be more expensive.


Workers run in every datacenter, but there are a variety of reasons your request might be rerouted to one that's not the closest one physically, such as:

* The closest one may already be at capacity, requiring rerouting some traffic away.

* ISPs in some parts of the world are weirdly fragmented, not interconnecting with other ISPs in the same region. As a result, if you're on the "wrong ISP", the network distance to the local colo may be longer than to some other colo that is physically further away.

* To serve content from servers in China, you must have an ICP license from the Chinese government. If you don't have that, Cloudflare will send Chinese traffic to the closest non-Chinese colo.

* Probably other reasons I'm not thinking of off the top of my head.

Note that all these apply to Cloudflare in general regardless of whether you use Workers. Enabling Workers has no effect on what datacenter you get routed to. Cloudflare's infrastructure team is always working to improve these situations, e.g. adding more servers, negotiating more connectivity, etc.

A nice thing about building on Workers is you don't have to worry about any of this. E.g. you don't need to think about redirecting your traffic when a colo is over capacity... it happens automatically.

(I'm the tech lead for Workers.)


Thanks for the reply.

I'm referring to e.g. https://community.cloudflare.com/t/does-free-plan-cloudflare... where the poster says:

"For predominantly Australian traffic, you’d probably need CF Business or Enterprise plan. For India traffic, would need CF Enterprise plan."

Where do workers run in this instance and what impacts are there say if I'm not on a business or enterprise plan?

Point being if we do need an enterprise or business plan for these features it's not 100% free.


Sorry, I'm not on the network team and I don't know whether that specific forum comment is accurate.

All I can say is that if you use Workers, the Worker always runs in the datacenter that receives your request, which is exactly the same datacenter that would have received your request if you weren't using Workers.


Legal | privacy