Skip to main content

zodb-pgjsonb

ZODB storage adapter for PostgreSQL using JSONB, powered by zodb-json-codec.

zodb-pgjsonb stores object state as queryable JSONB instead of opaque pickle bytea. ZODB sees pickle bytes at its boundaries; PostgreSQL sees queryable JSON internally.

  • SQL Queryability -- query ZODB objects directly with PostgreSQL JSONB operators and GIN indexes
  • Performance -- Rust-based codec, psycopg3 pipelined writes, pure SQL pack/GC (15-28x faster than RelStorage)
  • Tiered Blobs -- small blobs in PG bytea, large blobs in S3 (configurable threshold)
  • Full ZODB Compatibility -- IStorage, IMVCCStorage, IBlobStorage, IStorageUndoable, IStorageIteration, IStorageRestoreable
  • Security -- JSON has no code execution attack surface (unlike pickle deserialization)

Requires Python 3.12+, PostgreSQL 15+ (tested with 17).

Quick Start

%import zodb_pgjsonb

<zodb_db main>
    <pgjsonb>
        dsn dbname=zodb user=zodb password=zodb host=localhost port=5432
    </pgjsonb>
</zodb_db>
pip install zodb-pgjsonb          # or: pip install zodb-pgjsonb[s3]

Documentation

Full documentation: https://bluedynamics.github.io/zodb-pgjsonb/

Source Code and Contributions

The source code is managed in a Git repository, with its main branches hosted on GitHub. Issues can be reported there too.

We'd be happy to see many forks and pull requests to make this package even better. We welcome AI-assisted contributions, but expect every contributor to fully understand and be able to explain the code they submit. Please don't send bulk auto-generated pull requests.

Maintainers are Jens Klein and the BlueDynamics Alliance developer team. We appreciate any contribution and if a release on PyPI is needed, please just contact one of us. We also offer commercial support if any training, coaching, integration or adaptations are needed.

License

ZPL-2.1 (Zope Public License)

Metadata

Release files for zodb-pgjsonb 1.19.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for zodb-pgjsonb 1.19.1
File Size Uploaded Provenance Actions
zodb_pgjsonb-1.19.1.tar.gz 2.5 MB With provenance Details for zodb_pgjsonb-1.19.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for zodb-pgjsonb 1.19.1
File Interpreter ABI Platform Actions
zodb_pgjsonb-1.19.1-py3-none-any.whl Python 3 none any Details for zodb_pgjsonb-1.19.1-py3-none-any.whl

Total release size: 2.6 MB

Release files / zodb_pgjsonb-1.19.1.tar.gz

Download URL zodb_pgjsonb-1.19.1.tar.gz
Size 2.5 MB
Tags Source
SHA-256 checksum
How to use checksums
c42e960fc591caf388bb6ef706ffe9a3d906264915dfe430f2deaa2dd435410c
BLAKE2b-256 checksum
How to use checksums
a43dfd21cef2eae7ebb8eda345e5605d7e7f684bf36545d72d79203189f0d980
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 5, 2026.

Transparency log

Release files / zodb_pgjsonb-1.19.1-py3-none-any.whl

Download URL zodb_pgjsonb-1.19.1-py3-none-any.whl
Size 83.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b31469d609d3143ed256fd6152006422581910d8740fe6d6941bac2df50bbd51
BLAKE2b-256 checksum
How to use checksums
c8700d81c71d24b414a50f3dead7b0871d82b534fb6bcd45071024092b546c36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 5, 2026.

Transparency log

Security for zodb-pgjsonb 1.19.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for zodb_pgjsonb-1.19.1.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 5, 2026.

Transparency log

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

1.19.1 This release

2 release files Full provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page