Re: How do I schedule events for execution ?
- From: "Al Reid" <areidjr@xxxxxxxxxxxxxxxx>
- Date: Wed, 18 Jan 2006 09:05:27 -0500
<pamelafluente@xxxxxxxxx> wrote in message news:1137590881.969877.137220@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
> As pointed out by Randy, one problem with the sleep approach is related
> to system or program shut down. Assume that I have programmed a thread
> to weak up in 14 hours, 13 minutes, 30 seconds. What about if the
> system is shut down abruptly (for instance by a * power interruption *
> due to a black out ) and then restarted after 5 hours?
>
> Any idea to handle that?
>
> Can we program that a thread should start at a given time instead of
> expressing the duration of the sleep period?
>
A few questions.
1) Are we talking tens or hundreds of tasks?
2) What is the precision of the start times? I would expect it to be minutes, not hours.
3) What is the impact of a scheduled task starting one minute late?
4) Will another task be started before the previous task has completed or do they need to run in sequence.
Based on the answers to the above, I really don't think that the resources used to loop through the task list will be that great.
There is probably no need to fire the timer more frequently than about every 29 seconds. If multiple tasks will run concurrently,
then consider spawning them as separate threads or tasks, otherwise, they can all be executed from the scheduler's thread.
Just my $0.02.
Al Reid
.
- Follow-Ups:
- Re: How do I schedule events for execution ?
- From: pamelafluente
- Re: How do I schedule events for execution ?
- References:
- How do I schedule events for execution ?
- From: pamelafluente
- Re: How do I schedule events for execution ?
- From: Cor Ligthert [MVP]
- Re: How do I schedule events for execution ?
- From: pamelafluente
- Re: How do I schedule events for execution ?
- From: R. MacDonald
- Re: How do I schedule events for execution ?
- From: pamelafluente
- Re: How do I schedule events for execution ?
- From: pamelafluente
- How do I schedule events for execution ?
- Prev by Date: Re: looping through datareader
- Next by Date: Re: Typed DataSet
- Previous by thread: Re: How do I schedule events for execution ?
- Next by thread: Re: How do I schedule events for execution ?
- Index(es):
Relevant Pages
|