tagManager.resolve(tagPath) is returning null without logging into Publish? | Community
Skip to main content
Level 2
Jul 19, 2018 10:21 AM UTC
Solved

tagManager.resolve(tagPath) is returning null without logging into Publish?

Hi All,

I have written a servlet which will be executed when below url is called:

http://localhost:4503/content/experience-fragments/TestProject/en-us/banners.searchConditionalContent.json?tags=test/sources/512

This url fetch the correct data based on the query written in servlet service. Now on publish server, the data is fetched only if I am logged into Publish server through crxde. If I am not logged into the publisher through crx de the servlet is not responding the expected data. why?

I have created a system user for this service/servlet and used this session.

while debugging I found that :

While executing Tag tag = tagManager.resolve(tagPath); I am getting tag = null, where tagpath is /etc/tags/project/test/sources/512 which is published to the publisher. and I checked that this tag is available in the publisher. The respective content is also published.

Any pointers to find this? or debugging.

Thanks,

Manasi

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
edubey
edubeyAccepted solution
Level 10
Jul 22, 2018 6:23 AM UTC

By Default, Anonymous user will not have permission /etc/tags
Either you can provide permission or read this via service user which as permission

4 replies

smacdonald2008
Level 10
Jul 22, 2018 4:43 PM UTC

Also - we are running an Ask the AEM Community Experts on this on Tues - this is your chance to ask questions like this during the webinar -- Sign up here -- Scott's Digital Community: [Webinar | July ] Ask the AEM Community Experts: Adobe Experience Manager - Explore Assets a…

Translate
edubey
edubeyAccepted solution
Level 10
Jul 22, 2018 6:23 AM UTC

By Default, Anonymous user will not have permission /etc/tags
Either you can provide permission or read this via service user which as permission

Translate
AdobeID24
Level 5
Mar 26, 2020 6:43 PM UTC
FYI... I am using the CQ tag manager api... Tagmananger.resolve(tagid) this is returning as null everytime ... I mrunning in local as admin.... All tags are there I checked strictly.... Admin has all the permission .... Tagid is also correct like namesapce:fruit/apple kind of...... What can be problem.......
Translate
Employee
Jul 20, 2018 4:19 PM UTC

Go to useradmin, For everyone group make sure you have read permissions to /etc/tags and folder under it.

In AEM 6.4, the path for the tags would be /content/cq:tags. You can check for the same permission for the everyone group.

Translate