Expand my Community achievements bar.

SOLVED

Conditional Bulk publishing of Assets

Avatar

Level 1

Hi, 

We have to tree-activate the Assets by excluding the content fragments. Is there any OOTB feature OR any utility from ACS Commons, readily available to achieve this?
We don't want to write any scripts at this moment.
Appreciate your thoughts!

Thanks,
1 Accepted Solution

Avatar

Correct answer by
Community Advisor

Hi @mrudulm90837917 , as @diksha_mishra pointed out tree activation looks for folder level publishing and what you may do is 

1. Get a list of assets to be activated either from ACS aem commons report or OOTB assets report on cloud as CSV

 

2. Create a user on author and assign it to admin group, make sure it has write or replicate permission on the root path of your folder heirarchy.


3. Use this curl command as a reference, import it in Postman and this can be run as a collection on extracted csv

curl --location --request POST '<authorurl>/bin/replicate.json' \
--header 'Authorization: Basic xxxx' \
--form 'cmd="Activate"' \
--form 'path="{{Path1}}"' \
--form 'path="{{Path2}}"' \
--form 'path="{{Path3}}"'

It uses the OOTB /bin/replicate servlet where you can provide paths as input. You may consider creating a batch of 20 per request. Update the Basic Auth key as per the user created

If you have time constraints and want to replicate a large data set. Create a multithreaded Java programme and execute GET call in parallel threads from your local Java application. 




View solution in original post

3 Replies

Avatar

Community Advisor

@mrudulm90837917 Tree activation will always look for folder level publishing. For your requirement, you need a custom utility built as a part of MCP tools, that can consume an excel file containing Asset Paths that need publishing. Unfortunately, this is not available OOTB.

 

Avatar

Employee

Hi ,

 

You can try Bulk workflow manager of ACS Commons , write our query / specify asset paths and select a custom workflow for direct activation . 

https://adobe-consulting-services.github.io/acs-aem-commons/features/bulk-workflow-manager/index.htm...

You may have to create a simple custom workflow for direct activation of assets.

 

Regards

Divya

Avatar

Correct answer by
Community Advisor

Hi @mrudulm90837917 , as @diksha_mishra pointed out tree activation looks for folder level publishing and what you may do is 

1. Get a list of assets to be activated either from ACS aem commons report or OOTB assets report on cloud as CSV

 

2. Create a user on author and assign it to admin group, make sure it has write or replicate permission on the root path of your folder heirarchy.


3. Use this curl command as a reference, import it in Postman and this can be run as a collection on extracted csv

curl --location --request POST '<authorurl>/bin/replicate.json' \
--header 'Authorization: Basic xxxx' \
--form 'cmd="Activate"' \
--form 'path="{{Path1}}"' \
--form 'path="{{Path2}}"' \
--form 'path="{{Path3}}"'

It uses the OOTB /bin/replicate servlet where you can provide paths as input. You may consider creating a batch of 20 per request. Update the Basic Auth key as per the user created

If you have time constraints and want to replicate a large data set. Create a multithreaded Java programme and execute GET call in parallel threads from your local Java application.