


Hi,
I am writing script to replicate a page using groovy console. But I am always getting the Replicator instance as null.
What is the best way to get Replicator instance in groovy?
Thanks!
Views
Replies
Sign in to like this content
Total Likes
Hi @mvelicheti,
You can get Replicator object instance using getService method from Groovy Console
import com.day.cq.replication.Replicator
Replicator Replicator = getService(Replicator.class)
Alternatively you can use other build in methods like activate and deactivate in that case you do not need to get Replicator object.
acitvate("/content/path/page")
deactivate("/content/path/page")
Views
Replies
Sign in to like this content
Total Likes
Hi @mvelicheti,
You can get Replicator object instance using getService method from Groovy Console
import com.day.cq.replication.Replicator
Replicator Replicator = getService(Replicator.class)
Alternatively you can use other build in methods like activate and deactivate in that case you do not need to get Replicator object.
acitvate("/content/path/page")
deactivate("/content/path/page")
Views
Replies
Sign in to like this content
Total Likes