Performance issue with the My items functionality

  • Description

    The My items dialog box in the Content Editor or the Experience Editor is designed to locate and display items that are locked by the current user. The entire content tree must be inspected in order to do so. As the volume of content grows in the solution over time, the more time is spent on this operation.

    Possible solutions

    The Sitecore Platform architecturally allows a few ways of finding all items with a certain field value:

    • Sitecore Query
      The operation is executed on a Sitecore application level, causing all the items to be loaded into the process memory and have business rules applied (such as access control). The more content that is in the system, the longer it takes to process it initially. Subsequent requests are executed faster, thanks to a warm caching layer.
    • Sitecore Fast Query
      The operation is translated into a direct SQL statement, and it will bypass certain Sitecore logic and have better performance than Sitecore Query. The more content that is in the system, the longer it takes to execute the translated SQL query as it operates through the general-purpose Fields view. Subsequent requests will not take full advantage of the Sitecore caching layer as logic executed on a database level.
    • Content Search
      Indexing strategies refresh the index periodically, leaving the possibility of showing obsolete data. A covered index must exist to contain all the content in the database, which might violate the Item Buckets concept of one index per bucket.

    Summary

    Each approach provided by Sitecore architecture has its own benefits and drawbacks. Starting from Sitecore XP 9.0 Update-2, the seam was introduced to control the logic to fetch locked items.

  • Solution 1 (Applicable for Sitecore 7.2 — 7.5)

    Apply the following patch:

    1. Place the Sitecore.Support.419438.dll assembly into the \bin folder.
    2. Place the Sitecore.Support.419438.config file into the \App_Config\Include folder.

    Note: This patch can be applied only if you maintain the Quick search index. Please make sure that the index update interval is not set to "00:00:00":

    <-- INDEX UPDATE INTERVAL
    Gets the interval between the IndexingManager checking its queue for pending actions.
    Default value: "00:05:00" (5 minutes)
    -->
    <setting name="Indexing.UpdateInterval" value="00:05:00 />"
  • Solution 2 (Applicable For Sitecore 7.2 — 8.1 Update-2)

    Apply the following patch:

    1. Place the Sitecore.Support.419438.dll assembly into the \bin folder.

      Sitecore CMS 7.2 — XP 8.0: Sitecore XP 8.1:
    2. Place the Sitecore.Support.419438.config file into the \App_Config\Include folder.

      Sitecore CMS 7.2 — XP 8.0: Sitecore XP 8.1:
    3. If you are using Sitecore XP 8.0 or later, place the Sitecore.Support.131964.dll assembly into the \bin folder and the Sitecore.Support.131964.config file into the \App_Config\Include folder.

    4. Rebuild the sitecore_master_index.
  • Solution 3 (Applicable for 8.1 Update-3 and Sitecore 8.2)

  • Solution 4 (Applicable For Sitecore 9.0 Update-1)

    This solution loads locked items via a lightweight direct SQL query that is backed by an SQL filtered index leading to unlimited scalability and no performance drops with a growing volume of content.

    Apply the following patch:

    1. Place the Sitecore.Support.156916.dll into the \bin folder.
    2. Place the Sitecore.Support.156916.config file into the \App_Config\Include folder.
    3. Introduce the SQL-filtered index for the Sitecore Master database:
      CREATE NONCLUSTERED INDEX IX_Versioned_Locks_Filtered
          ON VersionedFields (itemID)
      INCLUDE (Value,language,version)
          WHERE FieldId='{001DD393-96C5-490B-924A-B0F25CD9EFD8}' -- this is lock fieldID
    4. Navigate to the \Website\sitecore\shell\Applications\WebEdit\Dialogs\LockedItems folder and change the x:inherits attribute in the LockedItems.xaml.xml file as follows:
      <Sitecore.Shell.Applications.WebEdit.Dialogs.LockedItems x:inherits="Sitecore.Support.Shell.Applications.WebEdit.Dialogs.LockedItems.LockedItemsPage,Sitecore.Support.156916">

Applies to:

CMS 7.2+

February 26, 2016
December 06, 2018

Reference number:

419438, 95319, 131964, 81747

Keywords: 

  • Performance