Re: C# service, performs lots of things on start, windows doesnt give it enough time!
- From: Jack Jackson <jacknospam@xxxxxxxxxxxxxxx>
- Date: Mon, 27 Aug 2007 13:23:55 -0700
On Mon, 27 Aug 2007 12:58:33 -0700, "test@xxxxxxxx"
<craig.whitcombe@xxxxxxxxx> wrote:
Hello all,
I am developing a windows service (c#, .net 2.0, windows 2003).
When the service starts it performs several functions that depend on
an internet connection, downloading rss feed etc.
The problem is, that if the connections is very slow, it takes a long
time for the status of the service to change from "starting" to
started, sometimes in fact, so long that windows gives up and says
that the service did not respond in a timely fashion.
If I wrap all my onstart functions into a timer.elapsed event instead,
the service status changes from starting to started instantly. I dont
like this though as it is not very eloquant. Is there a better way to
do this?
Many thanks,
Craig
What do you do if there is no Internet connection when your service
starts?
It makes sense to me to separate the starting of the service from the
processing that occurs when an Internet connection becomes available
(which might or might not be when the service starts).
.
- Follow-Ups:
- References:
- Prev by Date: Re: C# service, performs lots of things on start, windows doesnt give it enough time!
- Next by Date: Re: C# service, performs lots of things on start, windows doesnt give it enough time!
- Previous by thread: Re: C# service, performs lots of things on start, windows doesnt give it enough time!
- Next by thread: Re: C# service, performs lots of things on start, windows doesnt give it enough time!
- Index(es):
Relevant Pages
|
|