eventlet中的asyncio事件循环调度回调。
项目描述
这是[aioeventlet](https://github.com/magma/deb-python-aioeventlet)的一个分支,其中包含一些针对Magma项目中使用的较新版本的Python的补丁。它不维护,除非确保与Magma的兼容性。
aioeventlet在eventlet之上实现了asyncio API(PEP 3156)。这使得在目前为eventlet编写的项目中可以编写asyncio代码。
aioeventlet允许在asyncio协程中使用greenlets,并允许在greenlets中使用asyncio协程、任务和future:请参阅link_future()和wrap_greenthread()函数。
aioeventlet和trollius之间主要可见的差异是run_forever()的行为:在trollius中,run_forever()会阻塞,而在aioeventlet中,它会在greenlet中运行。这意味着aioeventlet事件循环可以在greenlet中运行,同时Python主线程并行运行其他greenlets。
版权/许可证:开源,Apache 2.0。祝您享受!