Re: Running CPU bound function concurrently in twisted
Gelin Yan <[email protected]> Mon, 24 Jun 2019 13:28:11 +0800
| Newsgroups | gmane.comp.python.twisted |
|---|---|
| Message-ID | <CABkOF6QaFYU0UncY2u2Yfz7RtW=zg9mPdzqXEzGGt2O4TOqDRw@mail.gmail.com> |
Hi If your purpose is merely not to block the reactor, you can run your code in a separate thread by using deferToThread. If you want to benefit from multi cores, you may consider use https://github.com/twisted/ampoule or other similar tools. Regards gelin yan _______________________________________________ Twisted-Python mailing list [email protected] https://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python