Expand my Community achievements bar.

Learn about Edge Delivery Services in upcoming GEM session
SOLVED

Scheduled activation programatically

Avatar

Level 4

Hi,

I have a requirement for scheduled activation programatically. Can somebody provide some pointer/source code for the same ?

Thanks

Sumit

1 Accepted Solution

Avatar

Correct answer by
Employee

There are a few ways to do this.

If you need some more help please reply.

View solution in original post

5 Replies

Avatar

Correct answer by
Employee

There are a few ways to do this.

If you need some more help please reply.

Avatar

Level 4

Thanks Graham for your reply.

I'm going to implement an OSGI component for this and I have requirement for bulk replication.

 I'm going to use replicator.replicate(), but I need to do it in batches so that It does not put load on our publisher.

How can I pass the date/time value programatically before I activate a batch is my question.

Is it possible to invoke 'chedule_activation' workflow  with a date/time programatically ?

Avatar

Level 1

Hi Any solution on this how to write custom  'schedule_activation' workflow  with a date/time programatically ?

Avatar

Employee

If this bulk activation is going to happen frequently I suggest that you shy away from workflows due to the overhead that they introduce.  I suggest that you set an activation limit, such as 100, and adjust the frequency that the job runs so to best work within your system constraints.  With each run you will chip away at the number of items that need to be activated.

What do you think?

Avatar

Level 4

Thanks again for sharing your thought.

Yes, I can have two osgi:config property ( one for the number for each batch and timeout value ). Seems that will do :)