@@ -52,19 +52,31 @@ supported calls for HLX6-backed projects or return `410 Gone` when unsupported.
5252### Helix 6 request handling
5353
5454Both da-admin and da-content resolve sites through the shared ` DA_SITE_BACKENDS `
55- KV binding. Keys are lowercase ` org/site ` ; values are the strings ` da ` or ` hlx6 ` .
55+ KV binding. Keys are lowercase ` org/site ` ; values are the strings ` da ` or ` hlx6 `
56+ (case and surrounding whitespace are normalized when reading).
5657An ` hlx6 ` site uses a synchronous compatibility bridge to ` AEM_API `
5758(` https://api.aem.live ` by default).
5859
5960On a cache miss, the worker makes an unauthenticated GET to
60- ` https://admin.hlx.page/ping/{org}/{site} ` with a 3s timeout. Presence of
61- ` x-api-upgrade-available ` identifies HLX6. Successful responses without that
62- header, and 404s for unregistered sites, identify DA. Both results are persisted
63- without expiration; cache hits do not ping. Concurrent lookups within one worker
64- are coalesced, but KV does not guarantee a single probe globally.
61+ ` https://admin.hlx.page/ping/{org}/{site} ` with a 3s timeout. Set ` HLX_ADMIN `
62+ to override the probe base URL per environment (for example in ` .dev.vars ` or
63+ the Cloudflare dashboard); local integration tests use the mock server.
64+ Presence of ` x-api-upgrade-available ` selects HLX6. This is a source-bus
65+ configuration heuristic, including overlays, ** not proof of completed cutover** .
66+ Explicit registry entries override it. Successful responses without that header
67+ select DA. Successful probe results persist without expiration; 404 results
68+ expire after ** 300 seconds** so not-yet-created sites can be detected later.
69+ Cache hits do not ping. Concurrent cold requests own their I/O independently;
70+ KV does not guarantee a single probe globally.
6571Redirects, auth/rate-limit/server errors, timeouts, invalid registry values, and
66- KV failures fail the request rather than assuming DA or writing legacy storage.
67- Only in-flight lookups are held in memory; subsequent requests read KV again.
72+ KV read failures fail the request rather than assuming DA or writing legacy
73+ storage. Failed KV writes are logged without discarding the known probe result.
74+ Subsequent requests read KV again.
75+
76+ Site listings require read or readable-descendant permission before backend
77+ detection. The 404 expiry limits retention, not traffic: signed-in users of open
78+ orgs, and public da-content requests, can still generate cold probes. This is
79+ not a rate limiter or an org-existence check.
6880
6981The bridge supports:
7082
@@ -74,10 +86,14 @@ The bridge supports:
7486 filtering. HLX6 listings are unpaginated; a legacy continuation token on a
7587 migrated site's listing is rejected.
7688- Org GET listings, merging legacy DA sites with the org's bridged HLX6 sites:
77- entries of ` GET /{org}/source/ ` (caller token, 3s timeout) resolved as HLX6
78- through the registry, filtered by DA ACLs. Org listings also discover sites
79- not yet cached. If the HLX6 listing or site resolution fails
80- (outage, timeout, missing HLX6 role), the DA listing is still returned.
89+ discovery runs only if the registry already contains a non-dual-writing HLX6
90+ site for that org. The gate uses paginated KV listing and bulk reads of at most
91+ 100 keys, without pinging. Entries of ` GET /{org}/source/ ` (caller token,
92+ 3s timeout) are filtered by DA ACLs before resolving their backends. Unknown
93+ sites can then be discovered. An entirely uncached HLX6-only org requires a
94+ direct site request or a seeded registry entry before discovery is enabled.
95+ Failed individual lookups are logged and omitted while healthy sites remain;
96+ if discovery is unavailable, the DA listing is still returned.
8197 Only the first legacy page adds HLX6 sites; subsequent pages preserve the
8298 DA continuation token without repeating them.
8399- Site editor-config GET and multipart PUT/POST (` config ` field), converting
@@ -134,9 +150,13 @@ Production uses the `DA_SITE_BACKENDS` namespace
134150Both workers bind the appropriate namespace as ` DA_SITE_BACKENDS ` . Local dev
135151and integration tests use emulated KV, not remote registry writes.
136152
137- Before deploying, seed any existing ` HLX6_MIGRATED_SITES ` entries as ` hlx6 `
138- in the corresponding namespace, then deploy da-admin before da-content.
139- The old environment variable is no longer read.
153+ Before deploying, preload ** all sites still served by DA** as ` da ` , including
154+ dual-write sites, and existing ` HLX6_MIGRATED_SITES ` entries as ` hlx6 ` in the
155+ corresponding namespace. Do not blindly overwrite existing authoritative entries;
156+ resolve conflicting inventory first. Preloading DA sites avoids making rollout
157+ depend on successful cold pings and prevents an overlay header from triggering
158+ premature cutover. Then deploy da-admin before da-content. The old environment
159+ variable is no longer read. Manual entries have no expiration.
140160
141161Before starting dual write, explicitly set the site's registry entry to ` da ` .
142162This keeps da-content on legacy routing even if a cold ping would identify the
0 commit comments