greenlets

Greenlet Vs. Threads

坚强是说给别人听的谎言 提交于 2019-11-27 08:55:55
问题 I am new to gevents and greenlets. I found some good documentation on how to work with them, but none gave me justification on how and when I should use greenlets! What are they really good at? Is it a good idea to use them in a proxy server or not? Why not threads? What I am not sure about is how they can provide us with concurrency if they're basically co-routines. 回答1: Greenlets provide concurrency but not parallelism. Concurrency is when code can run independently of other code.