diff --git a/.github/workflows/_checks.yml b/.github/workflows/_checks.yml index 0bc27fc..8129b13 100644 --- a/.github/workflows/_checks.yml +++ b/.github/workflows/_checks.yml @@ -97,6 +97,8 @@ jobs: # the same versions can still disagree on whether those versions install. # 3.14t is out: the dev group's `faststream[kafka]` pulls aiokafka, which ships no cp314t # wheel, so under --no-build this leg would measure upstream's gap rather than a floor. + # PostgreSQL 13 is the server floor: outbox_autovacuum_ddl sets the insert-triggered + # reloptions that 13 introduced. if: github.event_name != 'schedule' runs-on: ubuntu-latest strategy: @@ -109,7 +111,7 @@ jobs: - "3.14" services: postgres: - image: postgres:17 + image: postgres:13 env: POSTGRES_USER: outbox POSTGRES_PASSWORD: outbox diff --git a/docs/introduction/installation.md b/docs/introduction/installation.md index 43efa63..8beb192 100644 --- a/docs/introduction/installation.md +++ b/docs/introduction/installation.md @@ -23,10 +23,10 @@ ## Requirements - Python 3.11+ -- PostgreSQL 12+. The features used (partial indexes, `FOR UPDATE SKIP - LOCKED`, `make_interval`, `pg_notify`) all predate 12. The examples and - CI run on 17; that is what's exercised, so 17 is the safest choice if - you're starting fresh. +- PostgreSQL 13+. `outbox_autovacuum_ddl` sets the insert-triggered + autovacuum options that 13 introduced; on 12 the `ALTER TABLE` fails. + CI runs the test suite on 13 and on 17. The examples use 17, so that is + the safest choice if you're starting fresh. - A running Postgres instance accessible via SQLAlchemy `AsyncEngine` ## Free-threaded Python diff --git a/docs/operations/alembic.md b/docs/operations/alembic.md index 505b282..dd13ee6 100644 --- a/docs/operations/alembic.md +++ b/docs/operations/alembic.md @@ -209,7 +209,7 @@ def upgrade() -> None: ``` This sets `autovacuum_vacuum_scale_factor = 0` and `autovacuum_vacuum_threshold = -1000` (plus the insert-triggered pair, Postgres 13+). Tune the thresholds for your +1000`, plus the insert-triggered pair, which needs PostgreSQL 13 or later. Tune the thresholds for your message rate, for example `outbox_autovacuum_ddl("outbox", vacuum_threshold=5000, insert_threshold=5000)`.