[Custom Domains Feature] What is working, whats not

Hello👋 According to the Custom Domains for Workers (published 12.05.2022) feature it should be now possible to call workers within the same zone.

So I quickly jumped in and created some tests on what is fetching and whats not.

Setting:

  • App Worker: app.domain.tld, app.user.workers.dev
  • Api Origin Worker: api.domain.tld, api-origin.user.workers.dev
  • Api Worker: api.user.workers.dev (not affiliated with the domain)
  • No additional other route information given on the involved workers.

Outcome:

  • app.domain.tld :arrow_right: api.domain.tld :point_right: “” (empty return):exploding_head::x:
  • app.domain.tld :arrow_right: api-origin.user.workers.dev :point_right: :white_check_mark:
  • app.domain.tld :arrow_right: api.user.workers.dev :point_right: :white_check_mark:
  • app.user.workers.dev :arrow_right: api.domain.tld :point_right: :white_check_mark:
  • app.user.workers.dev :arrow_right: api-origin.user.workers.dev :point_right: “error code: 1042” :x:
  • app.user.workers.dev :arrow_right: api.user.workers.dev :point_right: “error code: 1042” :x:

Should it really be like that? Don’t think so. Most importantly, case 1 should work by the blog post but is completely not with an utterly empty response which is hard to debug. Is there any misconfig on my side when omitting the “old routes” config?

On a personal note I should add here that I spend quiet some time figuring that out😵 The (wrangler) dev vs. production situation is pretty much inverted which is super weird while developing against😕