Continua prevents machine from going to sleep

I recently installed Continua CI and since then my machine refused to go to sleep. Changing all continua services from automatic to manual allows the computer to go to sleep again.

Why does Continua prevent my machine from entering sleep?
What else can I do to both use Continua and have a computer that goes to sleep?

Thanks, Marjan

Umm… because Continua CI is not designed to run on desktop or laptops, it’s a server application designed to run all the time, continually checking repositories etc.

Thanks for the response and yes I figured as much.

Doesn’t help much though and I don’t think that “designed to run on a server” should be used as an “excuse” to keep a machine awake. Even servers should sleep and conserve energy when not accessed or used by client machines or their own processes. Continua should really allow a server to sleep and just wake it when it needs to do something. A product like Acronis True Image Home does exactly that. It allows my computer to sleep and wakes it when it wants to run a backup.

The pulling “Continually checking repositories” paradigm w/could perhaps be better changed. Pulling is very resource intensive. A push paradigm, where Continua goes to work when a repository signals that something has changed might be a better approach. It would be nice if at least Continua could be configured not to poll any repositories, or only do so on an infrequent schedule, waking the machine if needs be.

Continua does actually allow you to configure the polling interval, and you can set it to Manual mode, where a url needs to be hit to cause polling to occur (in the next polling interval).

http://wiki.finalbuilder.com/display/continua/Repositories

However, if your machine is asleep, that will not wake it up to do some work. There is a lot more to Continua CI than just repository polling though, the effort to implement suspending all background tasks (and ensuring they can resume in a consistent state) does not make economic sense.

Thanks, that may help. I am not too fussed about the machine not being woken up by Continua. I could schedule to (just after) the times that Acronis backs up - that usually only takes a couple of minutes out of the time before it goes back to sleep.

I understand there is a lot more to Continua. And I understand economic arguments. So no worries there. I am happy to have a work around avenue to explore.

Out of sheer curiosity:
I am pretty familiar with Windows service programming, but I’ll readily admit I have not yet looked deeply into this subject. Why you would need to suspend background tasks? Wouldn’t it “simply” be a matter of not doing stuff in those tasks that prevent the machine from going to sleep? There are plenty of services running on my machine at any one time that do not prevent it going to sleep. I somehow find it hard to imagine that the authors of those services jumped through hoops to ensure their applications survived a sleep state?

Kind regards, Marjan

It depends very much on what the background tasks are doing. If a thread is blocking while it runs another process (git for example) it can’t be suspended.

I’m not saying that we couldn’t implement the sleep support, it’s just not a high priority right now while we have a long backlog of features to implement.

Ah, yes, of course. Shoot and wait for a “callback” trigger isn’t an option and periodically (using windows events) checking some state would be awkward for that scenario. Hmm. Interesting conundrum. Anyways, fully understand that it isn’t a priority. Thanks for taking the time to satisfy my curiosity.