Knowing if an item is loaded from the database or a resource file is useful for developers when working with XM Cloud. It provides extra information when troubleshooting complex issues and could lead to a faster cause identification and resolution.
This new feature is inside the Developer ribbon tab. This tab is hidden by default. To enable the Developer ribbon tab:
On the right of the last ribbon tab, right click in in the dark gray area.
Select the Developer item to enable it.
Once enabled, you have access to many new actions.
In the Developer ribbon tab, Sitecore XM Cloud has a View section with an Item source toggle. Once enabled, all selected Sitecore content tree items now have an extra Source property in the right panel Quick Info section.
A resources source means that the item is stored in an Items as Resources (IAR) .dat file. Sitecore XM Cloud stores default items in resource files (source). Sitecore XM/XP also stores them in resource files from Sitecore 10.1 (source). Sitecore XM Cloud also package all your solution serialized item in resource files (one per database) at deployment time (source).
An item from a resource file cannot be deleted. When one of its field is modified, the whole item is copied to the database and starts being loaded from the database (source).
A database source means that the item is stored and loaded from the database. Items that have been manually created in an environment are stored in the database.
Also, items from resource files that are modified get copied and stored in the database (source). If such a database item is deleted, it reverts back to being loaded from the resource file.
This feature is available in:
For a local development environment, run the .\up.ps1
script to pull the latest Sitecore XM Cloud Docker
base images, rebuild your solution Docker images, and restart the containers.
For a deployed environment, in the Sitecore XM Cloud Deploy App, select the environment and run a “Build and deploy” action to redeploy your solution using the latest Sitecore XM Cloud Docker base images.
To troubleshoot advanced Items as Resources (IAR) issues, I highly recommend the Sitecore Item as Resource Explorer tool built by Sitecore Technology MVP Ghodrat Ashournia.
Thanks to Sitecore community members Robbert Hock and Nick Allen who helped me to find this hidden feature.
Happy Sitecoring!