I have been reading the docs for a couple of hours and I simply can't
find an answer to this:
How can I **stop** colubrid from inside the application?
The current code used to run the app is here:
http://ra-blog.googlecode.com/svn/trunk/BartleBlog/backend/web.py
Since I will run this in a thread in a desktop app, I want a way to
stop it when the user wants to quit.
BTW: I am using it for page previews in a desktop blogging tool...
Colubrid is pretty cool!
Blog post about it here: http://lateral.netmanagers.com.ar/weblog/2007/05/15.html#BB576
ralsina wrote:
> Hello!
>
> I have been reading the docs for a couple of hours and I simply can't
> find an answer to this:
>
> How can I **stop** colubrid from inside the application?
You cannot "stop" colubrid. But there are ways to stop the server it's
served in. Simplest way is grabing a reference to the WSGI Server (maybe
putting it into the environment) and killing it. Which WSGI Server are
you using?
Regards,
Armin
I suppose paste's, but I am not sure. How can I found that out?
Pass the application to a specific WSGI server. For example paste. The
colubrid execute function just tries a couple of WSGI servers.
But I don't think that any of the current existing WSGI servers provide
a functionallity to shut them down. Maybe raising KeyboardInterrupt
could help.
Regards,
Armin