Skip to content
This repository was archived by the owner on Apr 26, 2024. It is now read-only.
This repository was archived by the owner on Apr 26, 2024. It is now read-only.

[umbrella] Adding pg8000 as a database driver #9294

@ShadowJonathan

Description

@ShadowJonathan

Using pg8000, a pure-python postgres database driver, will make it possible to use pypy in a performant manner, as pypy has poor interaction with it's C-API.

This issue is thus a sub-issue of #8888, and tracks progress in integrating pg8000 into the codebase.

TODO

  • Pre: Generalize the current database drivers further to minimise engine-specific behaviour (Generalize the current database drivers further to minimise engine-specific behaviour #9298)
    • Adding in BaseDatabaseEngine.sql_type property to if-else based on "sqlite" or "postgres"
  • Pre: Rename PostgresEngine to PsycoPg2Engine (#XXXX)
  • Add Pg8000Engine (#XXXX)
  • Post: Add "postgres" "virtual" database name to switch to psycopg2 on cpython, and pg8000 on pypy (#XXXX)
  • Post: Add with engine.new_conn() as conn:-esc context manager usage everywhere, to ensure proper closure of cursors, transactions, and connections in pypy (#XXXX)

Metadata

Metadata

Assignees

No one assigned

    Labels

    T-TaskRefactoring, removal, replacement, enabling or disabling functionality, other engineering tasks.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions