Hi,
Tried checking replicator.replicate option for activate, but it only activates the node and not sub nodes, and node can be a sling folder or dam:asset.
The same with deactivate. Is this the expected behavior via api?
I would also like to avoid replication of a subfolder A, if there are children in that sub folder , that have not been replicated . Same with deactivation. What is the best approach other than traversal or query builder query? can/should sling query be used?
Solved! Go to Solution.
Views
Replies
Total Likes
Hi,
Use https://adobe-consulting-services.github.io/acs-aem-commons/features/bulk-workflow-manager/index.htm... for bulk publish/unpublish
I think i might have the answer, let me know your thoughts, not sure of any limitation wrt api
replicator.getActivatedPaths(session, path);- get the string path array and then deactivate.
String[] pathArray = pathList.toArray(new String[0]);
replicator.replicate(session, ReplicationActionType.DEACTIVATE, path);
Hi @NitroHazeDev ,
Activating the given path does not activate child node within that path. But It invalidates every page within that path in Dispatcher.
Tree Activation may helps in your case, please check here: https://aem4beginner.blogspot.com/how-to-perform-tree-activation-in-cq-aem
Regards,
Santosh
@SantoshSai Do you know of unpublish, based on my observations it is the same as replication where it is targeted to the specific path to activate or deactivate via api vs all it’s children. The problem is since not all resources may or may not be published , I can’t replicate the tree . By tree replication, first glance , it is iteration and activating one resource at a time ?
It invalidates but does not unpublish IMO ?
Hi,
Use https://adobe-consulting-services.github.io/acs-aem-commons/features/bulk-workflow-manager/index.htm... for bulk publish/unpublish