Product DocsMenu

Coveo Platform 6.5 >
Administrator Help > Connectors > Sitecore Legacy Connector > Enabling Live Indexing on a Database

Enabling Live Indexing on a Sitecore Database for the Legacy Connector

The Coveo connector for Sitecore supports live indexing to allow your Sitecore source to remain up-to-date as Sitecore content changes between index refreshes (see Toggling Live Indexing for a Source).

You must define the Sitecore Engines.HistoryEngine.Storage class in your Sitecore web.config file for the database that the connector source targets to make live indexing work.

To enable live indexing on a Sitecore database

  1. Using and administrator account, connect to the Sitecore server.

  2. Using a text editor:

    1. Open the Sitecore web.config file.

      Note: It is recommended to make a backup of the web.config file before editing it.

    2. In the <database> section for the desired website, add the Engines.HistoryEngine.Storage as shown in the following examples.

      Example: When your Sitecore source targets the site named website and the database serving this site is named web:

      • For Sitecore 6.0+

        <database id="web" singleInstance="true" type="Sitecore.Data.Database, 
        …
          <Engines.HistoryEngine.Storage>
            <obj type="Sitecore.Data.$(database).$(database)HistoryStorage, Sitecore.Kernel">
              <param connectionStringName="$(id)"/>
              <EntryLifeTime>30.00:00:00</EntryLifeTime>
            </obj>
          </Engines.HistoryEngine.Storage>
        …
        </database> 
        
      • For Sitecore 5.3

        <database id="web" singleInstance="true" type="Sitecore.Data.Database,
         …
          <Engines.HistoryEngine.Storage>
            <obj type="Sitecore.Data.$(database).$(database)HistoryStorage, Sitecore.$(database)">
            <param desc="connection" ref="connections/$(id)"></param>
            <EntryLifeTime>30.00:00:00</EntryLifeTime>
            </obj>
          </Engines.HistoryEngine.Storage>
        …
        </database> 
        
    Note: Every modification to the database of the site is considered when indexing on a live indexing run.

    You might experience a slow live indexing operation in some special design of your Sitecore website.

    Example: When your website counts page visits by modifying a metadata field, this marks the item as modified. The item is re-indexed on the next live indexing run. When CES crawls a Sitecore site, it might load every page to retrieve its HTML content (depending of your source options). In this case, the page visited counter is updated for each single page, causing each page to be marked as modified and re-indexed on the next live indexing run.

    If you must rely on metadata item fields that have to be modified on-the-fly, you can work around that limitation by checking the http request user agent before updating the database. When the Sitecore connector loads a page from the website, it uses the Coveo Sitecore crawler user agent.

What's Next?

When you want to index Sitecore permissions, create a user identity for the Sitecore crawling account (see Adding a User Identity) and a Sitecore security provider (see Configuring a Sitecore Security Provider for the Legacy Connector).

OR

Create your Sitecore source (see Configuring and Indexing a Source with the Sitecore Legacy Connector).