On 6/16/07, auser <[EMAIL PROTECTED]> wrote:
>
> Is it possible to access the threads of the scheduler and append a new
> schedule after the threads have been joined?
>
> for instance
>
> ...
> scheduler.start
> scheduler.schedule_every('1m') {puts "Hello World"}
> scheduler.join
> scheduler.schedule_every('10m') {puts "One more"}

Hi,

well, that's rather a ruby question than an openwferu-scheduler,
nevertheless it deserves an answer.

I could say : don't join before you're sure you want to join, but
that's no help.

>From another thread that sees the scheduler instance you can easily
add schedules.

You could have a scheduled job that checks a queue for further jobs to
add... But it means that there is another thread pushing the jobs on
the queue, and it'd be easier to let that other thread directly
scheduler jobs with scheduler.schedule_whatever().

Maybe you should not join and instead loop in your main thread waiting
for some input. Is this an interactive program ?

For me it feels like a program architecture issue, not an
openwferu-scheduler issue.


I hope this helps, best regards and happy hacking,

-- 
John Mettraux   -///-   http://jmettraux.openwfe.org

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"OpenWFEru users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/openwferu-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to