Publish server event for receiving replication? | Community
Skip to main content
October 16, 2015
Solved

Publish server event for receiving replication?

  • October 16, 2015
  • 8 replies
  • 2920 views

On a publish server, is there any Sling event you can listen to for receiving replication data??

The sling ReplicationAction only seems to fire on the source server (not the target).

Thanks!

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by JustinEd3

Tim-

Looking at the Events web console plugin, I have a guess why this isn't working for you. The event generated on the sending side (author) is under the topic com/day/cq/replication. The event generated on the receiving side (publish) is under the topic com/adobe/granite/replication. These are represented by the constants ReplicationAction.EVENT_TOPIC and ReplicationEvent.EVENT_TOPIC respectively.

Regards,

Justin

8 replies

Adobe Employee
October 16, 2015

Hi,

There is a ReplicationEvent generated on publish when a replication is received. I believe this was added in 5.6, but I could be wrong. It is definitely there in 6.0.

Regards,

Justin

smacdonald2008
October 16, 2015

If you are going to work at the JCR lvl and events - we have a how to general article for working with AEM and JCR events: http://helpx.adobe.com/experience-manager/using/events.html.

JustinEd3Adobe EmployeeAccepted solution
Adobe Employee
October 16, 2015

Tim-

Looking at the Events web console plugin, I have a guess why this isn't working for you. The event generated on the sending side (author) is under the topic com/day/cq/replication. The event generated on the receiving side (publish) is under the topic com/adobe/granite/replication. These are represented by the constants ReplicationAction.EVENT_TOPIC and ReplicationEvent.EVENT_TOPIC respectively.

Regards,

Justin

October 16, 2015

Thanks Justin - I think this is what we are looking for.

Can you please advise:  When you say "Events web console plugin" - what Console item is this?  Is this a separate plugin, and if so, where do I get it?

Kind Regards,

Tim

Sham_HC
October 16, 2015

Tim Goodman_BTES wrote...

 "Events web console plugin" - what Console item is this?

http://<host>:<port>/system/console/events

Sham_HC
October 16, 2015

What is exact use case?  Couple of  points need to take care & take a look at [1]

https://forums.adobe.com/message/4899883

http://aemfaq.blogspot.com/2013/05/chain-replication-sample.html

 
October 16, 2015

On the Publish server we want to detect content that is published (or a Flush request potentially), and perform some additional tasks in that zone.  We don't want to create a Replication agent for Flush requests

Sham_HC
October 16, 2015

Tim Goodman_BTES wrote...

On the Publish server we want to detect content that is published (or a Flush request potentially), and perform some additional tasks in that zone.  We don't want to create a Replication agent for Flush requests

 

Your use is not clear for a need. Anyhow you need to use jcr lower level or cq workflow level[1] Or own replication reciever(I won't recommend this).  An example with workflow at [2] for damassets & can modify script, config per your requirement. 

[1]   http://experiencedelivers.adobe.com/cemblog/en/experiencedelivers/2012/04/event_handling_incq.html

[2]   https://www.adobeaemcloud.com/content/marketplace/marketplaceProxy.html?packagePath=/content/companies/public/adobe/packages/daycare/DAM%20Asset%20Dispatcher%20flush