Hi Community
I have a requirement where when i select multiple assets and publish them , once all images got published i need to hit and external api and update the DB
So how can i check if all selected assets published and get list of the assets ??
Please help
Views
Replies
Total Likes
@adivj95 - I would suggest using a custom workflow which would:
ReplicationOptions options = new ReplicationOptions();
options.setSynchronous(true);
replicator.replicate(resourceResolver.adaptTo(Session.class), actionType, paths[], options);
Hope this helps!
Views
Replies
Total Likes
@adivj95 You can check this example replication event handler to run , it will look for Replication event. You have more control on adding logic to call the external API and send the list of assets. Please check it out.
https://gist.github.com/floriankraft/3710f30f4eaf212410a3
Views
Replies
Total Likes
Once you publish the asset, you can probably trigger a job, which will:
To check the status of the queue you can use following API:
AgentManager -> Agents (getAgents()) -> ReplicationQueue (getQueue()) -> getStatus()
Views
Replies
Total Likes