Not sure if this helps and where you want to print too, but you could deploy a bundle that implements the EventHandler class and listen for your required events.. I.e you can get the ReplicationAction using ReplicationAction.fromEvent(yourevent) and check if it matches the event of interest.
hope it helps..
One approach might be to check the audit log at /var/audit/com.day.cq.replication if on the author, nodes have the cq:Type of Activate/Deactivate.
(I have some sample code for starters here: http://www.eyelock.net/blog/archives/533)
This won't help if you purge your Audit Logs.
Does any property in the CRX for the page give me exact status if the page is in published state or not?
You need to activate a page and look in the CRX. You can then establish if there is anything in there that is useful for your requirement.
I activated a page and you can see some properties are set (such as cq:lastReplicationAction).
On the Publish server you can run the below query to see what Pages where activated during the dateTime range you need. Change the xs:dateTime values based on the date range that you need.
/jcr:root/content//*[@jcr:created >= xs:dateTime('2013-04-09T00:00:00.000+02:00') and @jcr:created<= xs:dateTime('2013-04-11T00:00:00.000+02:00') and jcr:primaryType='cq:PageContent']
Please note the filter - jcr:rimaryType='cq:PageContent' - in the query. Use this if you only want to check for the pages that got activated. You can remove this filter if you want to check for all content (like images, etc) that got activated.
The results of this query should give you a list of everything that is currently residing on the Publish within a date range when they were activated.
Hope this helps.
Hey guys, why are you dealing with the implementation details of the replication module?
The regular way to gather this information is:
Page page = ...
ReplicationStatus status = page.adaptTo(ReplicationStatus.class)