Expected latency difference between workers.dev and custom domain
I have a very simple /ping worker. I get ~85ms for a round trip to workers.dev, and ~50ms for a round trip to my custom domain. In general, is this expected, and if so, does anybody know the underlying reason why there's such a big difference?
4 Replies
workers.dev is going to be free routing, your custom domain is going to be your zone plan's routing (pro/biz/ent get better), there's also some differences within free routing.
I'd look at the Cf-Ray response header on both requests for the airport code of the location serving the response, or
/cdn-cgi/trace
path and colo=
lineThe COLOs are both the same between workers and custom domain iirc. I didn't know zone plans get different routing behaviors. Thanks!
If the colos are the same I wouldn't expect different performance, unless it was due to something else, like cache only does anything on custom domains, or maybe first request stuff for a larger worker
Yea, zone plans and argo change routing. Having Argo enabled gives you enterprise like inbound routing. It's not too big of an effect in North America or most of Europe, but it can result in bigger differences in Germany w/ DTAG (difference between being routed to East Coast vs local German colos), India (some ISPs route free to Europe), or Asia Pacific (often results in being routed to sin/hkg on free vs more local pops on highe rplans)
It was the same exact worker so shouldnt be anything different besides the domain