Hi All,
We are upgrading from AEM 6.2 to AEM 6.3. In one of our jsp we are trying to get tags using Tag Manager but in publish instance tag manger is not able to find tags as etc is hidden for anonymous user.
We are getting Tag Manager by adapting resourceResolver (implicit object).
TagManager tagManager = resourceResolver.adaptTo(TagManager.class); // Geting Tag Manager value
Tag tag = tagManager.resolve("/etc/tags/abc"); // When resolving tag is null
Iterator<Tag> iteratorTag = tag.listChildren(); // null pointer exception
Could you please help in finding solution.
Thanks,
Megha Gowroji
Solved! Go to Solution.
Views
Replies
Total Likes
The current use always need at least read access to resolve any path in this case its Tag. There is no other approach to resolve. You need to update your instance permissions.
Ref:
Views
Replies
Total Likes
Does you solution work in Author?
Views
Replies
Total Likes
Can you pls check user permissions for that tag or root tag. other that API looks straight forward.
Views
Replies
Total Likes
Ya it works on author and works on publish if we give etc permissions to anonymous user. Is it recommended to do it or any other approach?
Views
Replies
Total Likes
Permissions for root tag are not given for anonymous user. issue is when we are accessing page in publish with active login.
It works if etc/tags permissions are given for anonymous user in publish environment. Is there any other way to do it?
Views
Replies
Total Likes
The current use always need at least read access to resolve any path in this case its Tag. There is no other approach to resolve. You need to update your instance permissions.
Ref:
Views
Replies
Total Likes