Skip to main content

Publishing

Abstract

Overview of the Sitecore publishing operations and how indexes are updated.

Publishing content means triggering the Content Management role to copy items from the Master database to the publishing target: the Web database. You can start a publish operation manually or by setting up an automated publishing routine.

Before publishing, you can use the Content Management role to preview the content that that you intend to publish. Then, as a content author or administrator, you can publish the content.

You can trigger publishing operations on specific items, for example, on all items that have been changed since the last publish. You can also trigger a complete republish of the entire Master database.

The Sitecore Content Management role is used for previewing content before publication and for the actual publishing process.

For large-scale publishing needs such as when there are many simultaneous editors or a low tolerance for publishing latency, you can move publishing operations to a separate role and scale them as needed.

When publishing is complete, the Content Management role adds an event to the Web database. This event can be picked up by a Content Management or Content Delivery role configured to handle indexing. Sitecore lets you define and configure different indexing strategies depending on your system requirements and configuration.

The default indexing strategy is based on the database event queue. This is a scalable feature that makes it possible for different roles to signal and react to events in the system. The indexing strategy reindexes only newly published items. However, the strategy also defines a configurable threshold. When more than this number of items are published, the Content Delivery role does a full reindex of the entire Web index.

Sitecore ships with other standard indexing strategies. In addition, you can develop custom strategies.

After publishing, an event stored in the Sitecore Web database triggers indexing of the Web index.

The Web index role is used by the Sitecore search API to retrieve content quickly. The search can be free text or faceted and based on common properties or metadata. The Web index role also maintains specific feature indexes for Experience Platform functionality, such as the Federated Experience Manager.

As a final part of the publishing operation, the Content Delivery role clears relevant memory caches to serve the newly published content to visitors.

After deployment and in other cases, a complete reindexing of the Master and Web index must be performed by the Sitecore Content Management role.

In some cases, you must completely refresh all search indexes for Sitecore. Complete reindexing is, for example, necessary after deployments. The complete reindexing operation is triggered through the Sitecore control panel. Although this operation is always run on the Content Management role, which updates the Master database and Master index, it can also update the Web index.

For scaling or security reasons, you can define multiple publishing targets. This makes it possible to publish specific content areas to separate Web databases.

It is possible to publish content to multiple publishing targets. This is another way of letting Sitecore differentiate experiences.

In these situations, multiple Content Delivery roles can retrieve content from their own Web database and Web index.

Multiple Sitecore Content Delivery roles can fetch content from separate Web databases and indexes.

During publishing operations, published events are added to all target databases triggering indexing operations on the individual indexing roles.

Note

In the default configuration, the Content Management role can only access one set of Web database and Web index. Therefore, in these scaling scenarios, it is not possible for an administrator to manually trigger a reindex of the Web index for all publishing targets. You must have a custom solution to be able to reindex the multiple Web index roles.

The Content Publishing role is part of the optional Publishing Service module for for high-performance and high availability publishing in large-scale Sitecore setups. The publishing role is a separate .NET core application running as a separate web service, that can run on a separate server.

Sitecore offers a separate Content Publishing role for large-scale setups.

When you or a scheduled job triggers a publishing operation, the Content Management role triggers the Content Publishing role. The Content Publishing role then publish batches of items from the Master database to the target Web database. It is also responsible for updating the links database in the Core database.

The publishing role can be scaled horizontally. However, the architecture of the Sitecore publishing system is designed as a queue and does not allow parallel publishing. Horizontally scaling the Content Publishing role caters exclusively for high availability and automatic failover, not for increasing the throughput of publishing operations.

When the publish operation is complete, the Content Publishing role adds an event to the event queue in the Master database.

The Content Management role picks up the event and add an event to the event queue in the Web database. The indexing role, in this case the Content Delivery role, picks up the event and makes sure that indexes are updated and caches are cleared.

Refer to the Architecture and Roles documentation for privacy and security considerations for each role on the processing and aggregation data flow.