You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit c96cb13
Browse filesBrowse the repository at this point in the historyBrowse files
feat: bridge legacy reads and saves for migrated sites (#344)
* feat: bridge migrated DA reads and saves
Keep legacy DA clients usable after HLX6 cutover.
Require DA ACLs and caller-token HLX6 permissions.
Reject unsupported operations instead of writing stale storage.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* docs: document HLX6 compatibility helpers
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: harden HLX6 bridge after review
Build org listings from config so they no longer depend on HLX6.
Forward preconditions only for source reads/saves; reject redirects.
Guard malformed save Locations and map string upload types.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: list HLX6 source sites in org listings
Merge DA sites with GET /{org}/source/ and configured migrated sites.
Fall back to DA plus configured sites when HLX6 listing fails.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: point bridge errors to api.aem.live
Drop Helix 6 naming from client-facing error messages.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* refactor: list org HLX6 sites from source only
The HLX6 org source listing already includes migrated sites.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* test: cover HLX6 bridge error paths
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
* fix: address HLX6 bridge review feedback
List only bridged HLX6 sites in org listings, with a 3s timeout.
Dedupe org entries by path; keep save JSON on upstream 204.
Guard unparseable save Locations; infer untyped upload types.
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
---------
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
- Site/folder GET listings, converted to DA item fields and hidden-file
58
+
filtering. HLX6 listings are unpaginated; a legacy continuation token on a
59
+
migrated site's listing is rejected.
60
+
- Org GET listings, merging legacy DA sites with the org's bridged HLX6 sites:
61
+
entries of `GET /{org}/source/` (caller token, 3s timeout) that are also in
62
+
`HLX6_MIGRATED_SITES`, filtered by DA ACLs. If the HLX6 listing fails
63
+
(outage, timeout, missing HLX6 role), the DA listing is still returned.
64
+
Only the first legacy page adds HLX6 sites; subsequent pages preserve the
65
+
DA continuation token without repeating them.
66
+
- Site editor-config GET and multipart PUT/POST (`config` field), converting
67
+
between DA sheet wrappers and `config/editor/da.json` row arrays. The whole
68
+
AEM site configuration is never replaced.
69
+
- Source multipart PUT/POST (`data` field) and raw uploads, converted to HLX6
70
+
POST, including its image-import behavior and validation. String `data`
71
+
fields are accepted for `.html`, `.json` and `.svg` only (415 otherwise).
72
+
Successful saves return DA's source/edit/preview/live URL envelope and the
73
+
upstream ETag. Bodyless folder writes become trailing-slash POSTs.
74
+
Upstream redirects are rejected with 502.
75
+
76
+
All requests retain existing DA ACL checks and require the caller's Bearer
77
+
token and the corresponding HLX6 permissions. There is no service-token
78
+
elevation, mutation retry, or fallback to writable legacy storage. Responses
79
+
are private/no-store. Legacy UUID and permission-hint headers are not invented:
80
+
`x-da-id`, `x-da-actions`, and `x-da-child-actions` are unavailable on bridged
81
+
site responses. DA ACLs and HLX6 roles must be configured separately.
82
+
83
+
Version/history APIs, copy/move/delete, dedicated media uploads, GUID-specified
84
+
uploads, collaborative writes, and extensionless file uploads remain
85
+
unsupported and return 410. Raw `/.versions` and `/.history` access through
86
+
source/list is blocked. Multiple-author token headers are rejected rather
87
+
than silently selecting an author. HTML transformations, validation, request
88
+
limits, and empty-document restore points are not identical to DA.
89
+
90
+
Org config, authentication, logout, and CORS preflight remain available locally.
91
+
The bridge does not change the HLX6 editor's org-config inheritance behavior.
55
92
Sites configured for dual write in `HLX6_DUAL_WRITES` retain normal DA behavior
56
93
during migration, even if they also appear in `HLX6_MIGRATED_SITES`.
57
94
95
+
The companion da-content change routes migrated sites through its `daadmin`
96
+
binding before direct-R2 allowlists and asset opt-outs. Configure the same
97
+
migration variables on both workers, and deploy the da-admin bridge first.
98
+
Content path/cookie handling remains on the legacy host; no browser redirect
99
+
or Library URL rewrite is required for supported source reads.
100
+
58
101
### Helix 6 migration (dual write)
59
102
Sites listed in the `HLX6_DUAL_WRITES` env variable are being migrated to Helix 6. Every successful modification on those sites (source create/update/delete, folder creation, copy, move, version creation) is also propagated, in the background, to the Helix 6 source bus at `AEM_API` (`https://api.aem.live`) using the caller's IMS token. Failures are logged but do not affect the DA response.
0 commit comments