Opened 4 years ago

Last modified 4 years ago

#32092 closed New feature

Add an async db backend: asyncpg — at Initial Version

Reported by: Andrew Chen Wang Owned by: nobody
Component: Database layer (models, ORM) Version: dev
Severity: Normal Keywords: database
Cc: Triage Stage: Unreviewed
Has patch: no Needs documentation: no
Needs tests: no Patch needs improvement: no
Easy pickings: no UI/UX: no

Description

This ticket wishes to add an asynchronous DB backend, namely using asyncpg.

I've recently finished porting Django's cache to use async methods in an async context. I'm continuing along my opinion that we need to have the layer of the cake down, i.e. the cache and the db backends, before the rest of the async porting of Django can continue. Thus, I'd like to begin getting an async database backend as well using asyncpg for a future async Django ORM along with async template loading (since psycopg3 is not complete).

I don't have much experience with the ORM itself, but I'd like to get the work started. One of the reasons this hasn't been started grandly is mentioned in DEP 9:

A lot of this stems from the fact that the underlying database drivers are synchronous

from here and because Andrew, not me, is pretty busy lately. I think I can alleviate some of the workload by implementing this backend as a way to get started testing an async ORM.

Change History (0)

Note: See TracTickets for help on using tickets.
Back to Top