7 ms·
Be careful with aiohttp, async io is great, but the actual http parser in aiohttp is super slow. See https://magic.io/blog/uvloop-blazing-fast-python-networkin
by cshenton 9y ago
Be careful with aiohttp, async io is great, but the actual http parser in aiohttp is super slow.
See https://magic.io/blog/uvloop-blazing-fast-python-networking/ https://magic.io/blog/uvloop-blazing-fast-python-networking/ for a full write up.
I've been building stuff in sanic, which is built on uvloop and is super fast. I can recommend it if you're willing to sacrifice a bit of project maturity for a solid async webserver.
- e12e 9y agoI think the most interesting bit about that is that with a re-working of the http header handling, python could be within spitting distance of "best of breed" more or less out of the box (using async, not wrapping uvloop). And also, of course: benchmark first, optimize later.