[Twisted-Python] how to stop a service

Jean-Paul Calderone exarkun at divmod.com
Sat Jun 10 14:44:31 EDT 2006


On Sat, 10 Jun 2006 15:53:47 -0200, Manlio Perillo <manlio_perillo at libero.it> wrote:
>Manlio Perillo ha scritto:
>> Just to be sure.
>>
>> I have written a small application that do some computation, than stop.
>>
>> I have subclassed twisted.application.service.Service, because the
>> application do some persistence, and this seems to be the best solution (?).
>>
>> To stop the application/service I just have to call reactor.stop, "as
>> usual"?
>>

Yep.

>
>Just another question: when running application with twistd, how can I
>return error codes from my application to operating system?
>
>That is: where (and how) can I safely call os.exit?
>

There's no support for this yet.

Jean-Paul




More information about the Twisted-Python mailing list