Item processing pipelines

In this article

When you rebuild or refresh your Coveo for Sitecore indexes using the Sitecore UI or the Coveo Command Center, a Sitecore item goes through series of processes, or pipelines. Along this route, Coveo for Sitecore processes the item by adding the missing Coveo fields (for example, the BinaryData field to hold the item body) and metadata required the item needs to be complete. At the end of these processes, the item is sent to the Coveo Platform where it’s finally converted to the Coveo index item format and stored.

For the indexing process within Sitecore, Coveo supplies you with two item processing Coveo for Sitecore pipelines (the <coveoItemProcessingPipeline> and <coveoPostItemProcessingPipeline> pipelines), which you can leverage to modify Sitecore items, respectively, before and after they’re processed by Coveo for Sitecore. Coveo for Sitecore pipelines are defined as /configuration/sitecore/pipelines element children in Coveo .config files. In turn, these Coveo pipeline elements contain <processor> elements which reference a class in a Coveo DLL.

The coveoItemProcessingPipeline Pipeline | Coveo for Sitecore 5 The coveoPostItemProcessingPipeline Pipeline | Coveo for Sitecore 5

Simplified view of the indexing process in Sitecore. The light-purple stages are Coveo for Sitecore pipelines you can leverage to customize the process with your own processors.

Among all pipelines included in Coveo for Sitecore, item processing pipelines are among the most commonly customized ones. You can find their definitions in the /configuration/sitecore/pipelines section of the Coveo.SearchProvider.config file. To add your own processor, you should therefore add your changes to the Coveo.SearchProvider.Custom.config file.

Overview of the pipelines

The following table provides an overview of the two item processing pipelines available in Coveo for Sitecore.

Pipeline Purpose Description

coveoItemProcessingPipeline

Item pre-processing

Used to pre-process Sitecore items, allowing you to reject them, create entirely new virtual items based on them, or fetch associated items. Input and output items are of type Sitecore.ContentSearch.IIndexable. Received items haven’t been processed by Coveo for Sitecore yet.

coveoPostItemProcessingPipeline

Item post-processing

Used to post-process Sitecore items, allowing you to perform various customizations. Processors added to this pipeline have access to the original IIndexable object, as well as to the Coveo processed CoveoIndexableItem object, and therefore to all fields added by Coveo for Sitecore. Input and output items are of type Coveo.AbstractLayer.RepositoryItem.CoveoIndexableItem.