While testing those changes, I tried to create and edit a we.retail template with a non-admin user. It turns out there is an issue with the WeRetailCommerceSessionImpl. This class's super constructor is at some point initializes the LanguageManagerImpl class with the following resource:
Then the LanguageManager then travels this tree upwards until it finds "jcr:content/jcr:language". The problem is that /conf is locked down in general, and template authors are not allowed to read /conf/we-retail/settings/wcm and above. This leads to AccessDeniedExceptions and this seem's to break the template editing.
Somehow this sounds like a general issue with LanguageManager and /conf resources in general. But I was wondering how this is expected to work in the context of we.retail. Things like:
Do we just miss the required language properties at /conf/we-retail/settings/wcm/templates/t1/structure/jcr:content?
Is it correct to initialize a WeRetailCommerceSssionImpl at /conf/we-retail/settings/wcm/templates/t1/structure/jcr:content?
This issue is a false alarm. The AccessDeniedException is properly catched and logged and does not seem to be the root cause for the editing issue I experience. Please apologize the noise.
Hi I added permissions for the templates and policies in /conf/we-retail, see PR https://github.com/Adobe-Marketing-Cloud/aem-sample-we-retail/pull/91.
While testing those changes, I tried to create and edit a we.retail template with a non-admin user. It turns out there is an issue with the WeRetailCommerceSessionImpl. This class's super constructor is at some point initializes the LanguageManagerImpl class with the following resource:
/conf/we-retail/settings/wcm/templates/t1/structure/jcr:content
Then the LanguageManager then travels this tree upwards until it finds "jcr:content/jcr:language". The problem is that /conf is locked down in general, and template authors are not allowed to read /conf/we-retail/settings/wcm and above. This leads to AccessDeniedExceptions and this seem's to break the template editing.
Somehow this sounds like a general issue with LanguageManager and /conf resources in general. But I was wondering how this is expected to work in the context of we.retail. Things like: