Skip to main content

Publishing updates to content-heavy sites has always been a challenge, especially when it comes to shared components like footers. Sitecore XM Cloud’s new Edge Runtime Publishing v.2, which is currently still in experimental status, brings improvements to this process by making incremental publishing faster and more efficient. Let’s take a closer look at what’s changed, how it works, and what benefits it brings to your content management workflows.

The Problem: Slow Publishing with Shared Components

In traditional publishing workflows, making small changes to a shared component (like a footer) could trigger the republishing of all pages that use that component. On large sites with many pages, this could take a significant amount of time and cause unnecessary delays.

For example, updating a footer on a website with thousands of pages meant republishing every page that referenced it. This process could take hours, especially if personalization or language fallback features were involved, slowing down your entire publishing queue.

The Solution: Edge Runtime Publishing

Edge Runtime Publishing changes how Sitecore handles these updates. Instead of republishing every page that uses a shared component, the new system only publishes the updated component itself. This process reduces the overall publishing time by publishing smaller, targeted pieces of content rather than the entire page.

Key improvements with this approach include:

  • Publishing Individual Components: Shared components like footers are updated independently, rather than triggering a republish of all pages.
  • Dynamic Layout Assembly: Layouts are reassembled at runtime on the Edge, using updated content as needed.
  • Integrated GraphQL: With integrated GraphQL, data like the latest news or product updates are automatically fetched when the page is loaded, reducing the need for a full republish.

The result is faster publishing, especially for incremental updates or sites that rely on shared components or complex content structures.

Real-World Impact: Faster Publishing on Content-Heavy Sites

Let’s revisit the example of updating a footer. With Edge Runtime Publishing, updating the footer itself becomes much quicker, as only the component is published rather than all pages that reference it. This reduces the time needed to publish updates from hours to seconds, even on sites with large content libraries or multiple language variations.

This change is particularly helpful for content-heavy sites, where even small updates to shared components can otherwise cause significant delays in publishing.

Considerations and Trade-Offs

While Edge Runtime Publishing offers notable performance improvements, there are a few things to keep in mind:

  • Initial Response Time: Because the layouts are dynamically assembled on the Edge, the first request for updated content may take longer than usual. However, this can be mitigated by using a custom warm-up script triggered by the publish webhook.
  • Cache Variance: With multiple Edge locations around the world, you may see slight differences in how quickly content is cached in each region. These differences usually resolve within a few minutes.
  • Testing: As with any new feature, it’s a good idea to test the new publishing process in a staging environment before enabling it in production. This is especially important if you’re using features like language fallbacks or personalized content.

How to Enable Edge Runtime Publishing

If you want to take advantage of this feature in XM Cloud, here’s how to enable it:

  1. Add an environment variable named Sitecore_ExperienceEdge_dot_WorkerStoreEnabled and set it to TRUE.
  2. Deploy your environment to apply the change.
  3. Perform a full republish of all sites in the Deploy app (just once).

If you need to revert to the older publishing method, you can simply set the variable to FALSE, redeploy the environment, and republish the sites.

Is Edge Runtime Publishing Right for You?

Edge Runtime Publishing is still in experimental status, but for teams managing large, content-heavy sites, it offers a clear performance boost. While there are some trade-offs, such as slower initial response times, the ability to publish shared components faster and more efficiently can be a huge time-saver.

If you’ve struggled with slow publishing due to shared data sources or complex content structures, this feature is worth exploring. As Sitecore moves towards a general availability release, now could be a good time to try it out and see how it fits into your workflows.

Dive Deeper into Edge Runtime Publishing

For a deeper understanding of the architecture and benefits of Edge Runtime Publishing, check out the Sitecore Stories – XM Cloud Publishing video. In this video, Ivan Lieckens, Senior Product Manager at Sitecore, and Rob Earlam, Head of Developer Advocacy at Sitecore, explain the details of this new publishing process:

Merry Christmas & happy Sitecore-ing!

–Robbert