Quantcast
Channel: Hasen Judy
Viewing all articles
Browse latest Browse all 50

Gevent? Coroutines for Flask?

$
0
0

Yesterday I was reading random stuff on the internet, one thing led to another, and I discovered there’s something called “greenlets” in python, which seem to be essentially coroutines of some sort.

The Flask docs mention that you can deploy flask apps using gevent:

http://flask.pocoo.org/docs/deploying/wsgi-standalone/#gevent

Gevent

Gevent is a coroutine-based Python networking library that uses greenlet to provide a high-level synchronous API on top of libevent event loop

It seems to monkey-patch existing synchronous apis to make them work with greenlets/coroutines, or something to that extent.

I haven’t actually figured out what’s going on, but this seems to be interesting.


Viewing all articles
Browse latest Browse all 50

Trending Articles