I'm having issues while rendering the tag titles on the publish server (AEM 6.1). I'm not facing this issue on Author environment as I'm logging as 'admin' user and even if I login as admin user on the publish server then tag names are rendering properly. I have checked the following options, in both the cases title is null
Option -1
tagPath =/etc/tags/<my tag>
Resource tagResource = resource.getResourceResolver().getResource(tagPath); //Resource is not null but tagResource is returning null
if(tagResource !=null){
Tag tag = tagResource.adaptTo(Tag.class);
title = tag.getTitle();
}
Option2
tagManager = resourceResolver.adaptTo(TagManager.class); //tagManager is not null here but Tag is returning null
Tag tag = tagManager.resolve(tagPath);
Solved! Go to Solution.
Views
Replies
Total Likes
Hi RJ,
Check out the documentation about setting tag permissions :
"As of AEM 6.1, 'secure (by default)' is now a best practice for the publish environment that requires read permission to be explicitly allowed for tags. Bascially, this is done by creating a package of the Tag Namespace after permissions have been set on author, and installing the package on all publish instances..."
- JK
Views
Replies
Total Likes
Hi RJ,
Check out the documentation about setting tag permissions :
"As of AEM 6.1, 'secure (by default)' is now a best practice for the publish environment that requires read permission to be explicitly allowed for tags. Bascially, this is done by creating a package of the Tag Namespace after permissions have been set on author, and installing the package on all publish instances..."
- JK
Views
Replies
Total Likes
As JK mentioned, its a ACL problem, provide the read access to the tags node and it should solve the issue.
Views
Replies
Total Likes
YRJ wrote...
I'm having issues while rendering the tag titles on the publish server (AEM 6.1). I'm not facing this issue on
Author environment as I'm logging as 'admin' user and even if I login as admin user on the publish server then tag names are rendering properly. I have checked the following options, in both thecases title is null
Option -1
tagPath =/etc /tags/<my tag>
Resource
tagResource = resource. getResourceResolver ( ). getResource ( tagPath ); //Resource is not null buttagResource is returning nullif ( tagResource ! =null) {
Tag tag =tagResource . adaptTo ( Tag. class);
title = tag. getTitle ( );
}
Option2
tagManager =resourceResolver . adaptTo ( TagManager. class); //tagManager is not null here but Tag is returning null
Tag tag =tagManager . resolve( tagPath );
Do I need to create system users to access the Tags on 6.1
?
Can you please help me in solving this issue?
Thanks in advance
RJ
As everyone pointed out correctly that you have to set read permission for the tags. And, just make sure, you set read permission for everyone group. Because that's how you can be sure that every new/old user has access to your tags.
--
Jitendra
Views
Replies
Total Likes
Thanks JK, bsloki and Jitendra! Really appreciate it!
Views
Replies
Total Likes
Views
Likes
Replies