I'm working on improving eventlet:
http://devel.ag-projects.com/~denis/eventlet/Eventlet is a networking library that uses greenlet, Python implementation of
coroutines [http://codespeak.net/py/0.9.2/greenlet.html] to handle
asynchronous events in a synchronous way. Greenlet can be thought as an
analogue to Python's enhanced generator, however, without "yield" keyword
and the limitations it brings.
For the applications that are network-bounded it effectively brings Erlang-like
scalability in Python: you can spawn as many greenlets as you like (they're cheap)
(e.g. one or several per incoming connection), control their execution, etc.
If that sounds unclear, just look at the examples:
http://devel.ag-projects.com/~denis/cgi-bin/hgweb.cgi/file/t...
http://devel.ag-projects.com/~denis/cgi-bin/hgweb.cgi/file/t...
http://devel.ag-projects.com/~denis/cgi-bin/hgweb.cgi/file/t...
Compared to the original eventlet (home - http://wiki.secondlife.com/wiki/Eventlet)
our branch has
- a number of bugs fixed and "onions" removed
- twisted integration - you can use any twisted reactor or twisted protocol or
any other feature you like (this part is heavily influenced by corotwine)
- proc module for advanced coroutine control (spawn, link, waitall, etc)