-
Notifications
You must be signed in to change notification settings - Fork 0
1. End‐to‐End Flow
Tanju Erinmez edited this page Apr 27, 2025
·
30 revisions
fstab mountpoint url:
mountpoints:
/:
url: "https://author-p130360-e1272151.adobeaemcloud.com/bin/franklin.delivery/adobe-rnd/aem-boilerplate-xwalk/main"
type: "markup"
suffix: ".html"publishBaseUrl:
https://main--aem-boilerplate-xwalk--adobe-rnd.aem.livesequenceDiagram
actor author as Author
participant helix as Edge Delivery Services
box lightslategray: <br/>author-p{programId}-e{envId}.adobeaemcloud.com
participant aem as AEM Author Instance<br/>(JVM)
end
author ->> aem: presses "Publish"
activate aem
aem -->> author: "acknowledged"
aem ->> helix: publish
deactivate aem
activate helix
author ->> helix: GET {publishBaseUrl}/articles/article-1
helix -->> author: returns "current HTML"
rect rgba(200, 200, 255, 0.3)
Note right of aem: This is the focus of the Hackathon.
helix ->> aem: GET {fstab mountpoint url}/articles/article-1
activate aem
aem -->> helix: returns HTML
deactivate aem
end
helix ->> helix: publishes new HTML
deactivate helix
author ->> helix: GET {publishBaseUrl}/articles/article-1
activate helix
helix -->> author: returns "new HTML"
deactivate helix
| AEM (Java‑based) | |
|---|---|
| Pros | Cons (solve it in Hackathon?) |
|
|
Approach:
- Route the traffic to a Worker that knows the XWalk specifics
- Use the new Content API as the Abstraction Layer (AEM Pages vs. JCR Data)
- Implement the Content API as a Service (Cloudflare Worker) too, to benefit from the rapid feature development cycle
fstab mountpoint url:
mountpoints:
/:
url: "https://xwalk-renderer-poc.adobeaem.workers.dev/xwalkpages/p130360_e1272151_1534567d-9937-4e40-85ff-369a8ed45367/main"
type: "markup"publishBaseUrl:
https://main--te-sites-content-api-poc--terinmez.aem.live/sequenceDiagram
actor author as Author
participant helix as Edge Delivery Services
participant xwalk as XWalk Renderer (Cloudflare)
box lightslategray: <br/>author-p{programId}-e{envId}.adobeaemcloud.com
participant pages as /adobe/pages Service (Cloudflare)
participant aem as AEM Author Instance<br/>(JVM)
end
author ->> aem: presses "Publish"
activate aem
aem -->> author: "acknowledged"
aem ->> helix: publish
activate helix
helix -->> aem: "acknowledged"
deactivate aem
helix ->> xwalk: GET {fstab mountpoint url}/articles/article-1
activate xwalk
author ->> helix: GET {publishBaseUrl}/articles/article-1
helix -->> author: returns "current HTML"
xwalk ->> pages: GET /pages/byUrl?url=`{fstab mountpoint url}/articles/article-1`
activate pages
pages ->> pages: 1️⃣ determineAemSiteNameBySiteId(), unless cached
activate pages
pages ->> aem: /bin/querybuilder.json
activate aem
aem -->> pages: returns /conf/{aemSiteName}/ in jcr:path (JSON)
deactivate aem
pages -->> pages: returns aemSiteName
deactivate pages
pages ->> pages: 2️⃣ determinePageInfoByAemSiteNameAndPagePath()
activate pages
pages ->> aem: /bin/querybuilder.json
activate aem
aem -->> pages: returns JCR Node Hits (JSON)
deactivate aem
pages -->> pages: returns pageId, siteId, parentPageId ...
deactivate pages
pages -->> xwalk: returns page data with pageId (JSON)
deactivate pages
xwalk ->> pages: GET /pages/{pageId}/content
activate pages
pages ->> aem: GET /_jcr_id/{pageId}.6.json
activate aem
aem -->> pages: returns JCR Nodes (JSON)
deactivate aem
pages ->> pages: json2html()
pages -->> xwalk: return page content (HTML)
deactivate pages
xwalk -->> helix: returns HTML
deactivate xwalk
deactivate helix
author ->> helix: GET {publishBaseUrl}/articles/article-1
activate helix
helix -->> author: returns "new HTML"
deactivate helix
| Cloudflare Workers (Javascript‑based) | |
|---|---|
| Pros | Cons (solveable?) |
|
|
Approach:
- enrich the Content API in such a way, that the Helix to Content API translation is not needed anymore
- Implement the Content API on the AEM Instance in such a way, that the Content Tree is logically exposed as JSON and read/write roundtrips are made possible
- For new functionality use the API Router flexibility to prototype new Content API endpoints in a Cloudflare Worker first, such as rendering the HTML in Javascript in a Worker, before Implementing them in Java.
fstab mountpoint url:
mountpoints:
/:
url: "https://author-p130360-e1272151.adobeaemcloud.com/adobe/sites/1534567d-9937-4e40-85ff-369a8ed45367/contentByPath"
type: "markup"sequenceDiagram
actor author as Author
participant helix as Edge Delivery Services
box lightslategray: <br/>author-p{programId}-e{envId}.adobeaemcloud.com
participant pages as /adobe/pages Service (Cloudflare)
participant aem as AEM Author with Content API<br/>Instance (JVM)
end
author ->> aem: presses "Publish"
activate aem
aem -->> author: "acknowledged"
aem ->> helix: publish
activate helix
helix -->> aem: "acknowledged"
deactivate aem
helix ->> aem: GET {fstab mountpoint url}/articles/article-1
activate aem
aem -->> helix: 303 See other Location: /adobe/pages/<article-1 pageId>
deactivate aem
author ->> helix: GET {publishBaseUrl}/articles/article-1
helix -->> author: returns "current HTML"
helix ->> pages: GET text/html /adobe/pages/<article-1 pageId>
activate pages
pages ->> aem: GET /adobe/pages/<article-1 pageId>/content
activate aem
aem -->> pages: returns Content API Content Tree as JSON
deactivate aem
pages ->> pages: contentTreeJson to HTML
activate pages
pages -->> pages: returns HTML
deactivate pages
pages -->> helix: returns HTML
deactivate pages
deactivate helix
author ->> helix: GET {publishBaseUrl}/articles/article-1
activate helix
helix -->> author: returns "new HTML"
deactivate helix