Forum OpenACS Q&A: Re: schedule proc memory

Collapse
2: Re: schedule proc memory (response to 1)
Posted by Claudio Pasolini on
... if a restart happens between the time I called ad_schedule_proc and the middle of the night, the scheduled proc is gone ...

Why? If you put your ad_schedule into a library sourced at aolserver start it will be scheduled again.

Collapse
Posted by Malte Sussdorff on
This is the whole point, ad_schedule_proc is called not by the library but when adding a user to the system.

Background: I need to add a user to 300 communities. Doing this during office hours will get us killed (because of the performance drain involved). Luckily I can delay this and schedule the creation to run in the middle of the night. But what happens if the system is restarted between the user adding and the execution time in the middle of the night?

Collapse
Posted by Steve Manning on
I would schedule the proc to always run and then get it to check for some other trigger to decide if it needs to actually do anything.

We use a similar idea for scheduled reports which we produce overnight from polled sales data.

- Steve