Debugging AEM as a Cloud Service with Repository Browser
Repository Browser is a powerful tool that provides visibility into AEM鈥檚 underlying data store, allowing for easy debugging of AEM as a Cloud Service environment. Repository Browser supports a read-only view of the resources and properties of AEM on Production, Stage, and Development, as well as Author, Publish, and Preview services.
Let鈥檚 quickly check out the AEM as a cloud service repository browser, which provides an easy way for developers to inspect the underlying data repository AEM runs on, and is a great tool to help debug AEM.
First, ensure that your user is a member of the cloud manager developer role. Then, from cloud manager, identify the AEM environment whose repository you want to browse, open its developer console, and, from within here, select the repository browser tab.
Before we open the repository browser, it鈥檚 important to ensure the appropriate service tier is selected. Since you can discretely browse author, or publish, or preview, it doesn鈥檛 matter which pod from the tier you pick. But, for clarity, I like to use the all selections. So, I鈥檒l select All Authors to browse the author repository.
And then I can select Open the Repository Browser. The repository browser itself is simple, yet effective. It provides a read-only view of AEM鈥檚 repository, displaying the resource tree and properties. Keep in mind that the repository browser only displays resources your user is entitled to see. So, if your user is part of the AEM administrators, you鈥檒l see everything. If not, your view into the repository will be limited to the permissions available to your user. Note that, if you鈥檙e going to open the publish or preview tier in the repository browser, review the documentation on how to ensure your permissions are properly set up.
Okay, let鈥檚 check it out. Drill under the resource tree by selecting the chevron to the left of each resource, and let鈥檚 drill down into a dam asset. So, we鈥檒l head down into content, dam and, continue on.
Here鈥檚 our asset, and let鈥檚 go a little further, to the metadata resource.
We can review the resource鈥檚 properties by selecting the resource itself, and you can see our properties show up here on the right. And we鈥檒l see the property name, as well as its value. Just a quick note, multi-value properties are displayed in brackets with comma separation.
So, the repository browser also provides a preview of certain file-based resources. For example, selecting an asset rendition provides an in context preview.
And we can, of course, download any of these files to our local machine.
Repository browser has some additional smarts as well. So, for instance, selecting a dam asset which has multiple file-based resources beneath it, which are its renditions, provides a preview of all of the renditions along the top, allowing us to click through them for a quick preview. You can see that not only images are supported, but also some text-based files as well.
Similarly, we can view code resources under /apps or /libs using the same approach.
Simply locate and select the code file, and open its preview.
You can debug permissions as well by inspecting access control lists, by opening the rep policy nodes, interviewing the allow and deny entries.
Lastly, it鈥檚 worth noting that the repository browser shows all resources, and, by this, I mean Sling resources rather than JCR nodes.
For this reason, you may see resources listed here that are provided via resource providers, and properties added via resource decorators, even though they may not exist as true JCR nodes or properties. So, for example, /is and /mnt, or mount, are not actual JCR nodes, but rather provided by the Sling. So, just be aware of this, especially if you鈥檙e debugging code that uses the JCR APIs rather than Sling鈥檚 resource APIs.
Okay, hope this gives you a quick overview of the repository browser. Happy debugging. -
Repository Browser is ONLY available on AEM as a Cloud Service environments (use CRXDE Lite to debug the local AEM SDK).
Accessing Repository Browser
To access Repository Browser on AEM as a Cloud Service:
-
Ensure that your user has the required access
-
Log in to
-
Select the Program containing the AEM as a Cloud Service environment to debug
-
Open the Developer Console corresponding to the AEM as a Cloud Service environment to debug
-
Select the Repository Browser tab
-
Select the AEM service tier to browse
- All Authors
- All Publishers
- All Previews
-
Select Open Repository Browser
The Repository Browser opens for the selected service tier (Author, Publish, or Preview) in a read-only mode, displaying resources and properties your user has access to.
Publish and Preview access
By default, access to Publish or Preview is limited, reducing the available resources in Repository Browser. To view all resources on Publish (or Preview) add users to a Publish (or Preview) Administrators role.