Just Add Await: Retrofitting Async Into Django
summary
The project retrofits async by adding ASGI support in Django 3, a compatibility layer that uses sync_to_async/async_to_sync shims and a thread-sensitive mode to keep thread-local and SQLite behavior safe; phase two makes handlers, middleware and views async (branch passes all but two tests) and full ORM async is planned later. Claim: properly used async views can yield 5–10x efficiency on IO-bound workloads. Middleware and class-based views remain the hardest compatibility problems.
AI-written summary · about
chapters (31)
- 0:00Introduction
- 1:52Sinking Brief
- 5:15Why not just use threads
- 8:41Django is a big framework
- 10:05Django is built on thirdparty libraries
- 12:45Django doesnt have an async equivalent
- 13:50Threads do matter
- 15:17We have to play up
- 16:09Django Internals
- 18:02Phase 1 SGI
- 20:04Djangopredates WSGI
- 24:36Uploading files
- 25:38ASCIIRare
- 27:46Phased Approach
- 32:59Classbased views
- 34:03The goal
- 34:29Error Ram
- 34:39API Design
- 35:05Select Related
- 35:24Phase Approach
- 35:46DjangoORM Safety
- 35:59DjangoORM Error
- 36:11Need Help
- 36:44Some Things Dont Need Async
- 37:19Async Views
- 37:55Performance
- 38:32Burnout
- 39:36Funding
- 40:21Django Forum
- 41:24Why Async
- 43:43Links
related talks
01h 10mJust Add Await: Retrofitting Async Into Django
32mAsynchronous Django: Unlocking the Power of Async Programming
21mIs Django async yet?
25mTaking Django's ORM Async
27mTaking Django Async
40mTaking Django Async
26mSync or async? Feel the magic of coroutines and the event loop in Django
23mµDjango, an Asynchronous Microservices Technique with Practical Examples
