Skip to content

Releases: pgdogdev/pgdog

v0.1.36

09 Apr 22:30
eb5ab65

Choose a tag to compare

What's Changed

  • feat: parallelize copy data & schema sync across shards
  • feat: change default setting value for query_cache_limit to 1000 to avoid heavy memory usage on first deployment
  • feat: log warning if re-sharding replication is missing rows; this if only impactful is using copy-data without --replication-only flag and shouldn't happen under normal state
  • feat: add 53-bit unique ID generator for apps that pass IDs directly to JS frontends
  • feat: add user-friendly interface to create sharded sequences (pgdog.install_sharded_sequence pl/pgsql function)
  • fix: use correct backend data type for cross-sharded count(*), fixes count(*)::int returning incorrect count
  • fix: oid is u32, not i32; affected old databases with schema churn (oid exceeded 2.2B)
  • fix: omnisharded table re-sharding: copy and replication copied the same table N times (N = number original shards)
  • chore: regression testing for unique id
  • chore: migrate to RWX for CI by @kylekthompson
  • chore: resharding integration tests
  • fix: detect SELECT ... FOR UPDATE inside CTEs
  • fix: potentially dropping child table rows during streaming replication / re-sharding

New Contributors

Full Changelog: v0.1.35...v0.1.36

v0.1.35

03 Apr 18:09
12f2a79

Choose a tag to compare

What's Changed

  • feat: DDL-only/DML-only mirroring
  • fix: much faster schema loading query, works with databases with many tables
  • fix: invalid keep-alive settings are just a warning now, won't cause a crash
  • fix: race in extended_anonymous prepared statements
  • fix: deadlock in sharded SELECT ... WHERE IN ($1, $2, $3)
  • fix: handle LIMIT $1 where $1 is null using the extended protocol
  • fix: logical replication Delete message generated incorrect parameters with compound identity columns
  • chore: add postgres.js tests to CI

Full Changelog: v0.1.34...v0.1.35

v0.1.34

24 Mar 19:28
f0613c1

Choose a tag to compare

In-transaction connections deadlock

If you're using v0.1.31 or later, please upgrade to v0.1.34 asap. This release fixes a deadlock caused by clients disconnecting mid-transaction.

What's Changed

  • fix: client disconnect inside transaction caused deadlock
  • chore: fix clippy issues by @meskill

Full Changelog: v0.1.33...v0.1.34

v0.1.33

23 Mar 18:16
ab60138

Choose a tag to compare

What's Changed

  • feat: PgDog-supported plugin for routing queries using table names (e.g., for primary-only routing)
  • feat: allow passthrough auth user to change its password
  • fix: Passthough -> Passthrough typo @rissson
  • fix: mirror prepared statement mode in session pooling @costi
  • fix: correctly handle Relation message sent inside transaction during logical replication (used for resharding)
  • fix: correctly forward only one Postgres error to the client, using the error code provided by Postgres server
  • fix: correctly handle FATAL / PANIC errors (force close the connection in the pooler) without banning host
  • fix: dependabot reporting security issues in integration tests repo-wide (e.g., Rails, Python, etc.) @meskill

New Contributors

Full Changelog: v0.1.32...v0.1.33

v0.1.32

12 Mar 21:21
e3a9fe5

Choose a tag to compare

What's Changed

  • feat: weighted load balancing
  • fix: schema sharding in session mode with cross_shard_disabled
  • feat: add configurable log format and level by @levish0

New Contributors

Full Changelog: v0.1.31...v0.1.32

v0.1.31

05 Mar 22:47
d9e3be6

Choose a tag to compare

What's Changed

  • feat: online resharding with zero downtime, incl. admin commands to orchestrate it
  • feat: RDS IAM authentication support for server connections @Tolsto
  • feat: handle RESET command
  • feat: ban replicas if replica lag is high (configurable)
  • feat: config linting and validation with jsonschema, incl. language server support @meskill
  • fix: replication stream broke due to parser changes, added regression tests
  • fix: update verify_ca implementation for rustls 0.23, fixes Aurora TLS connections with verify_ca (verify_full worked already) @quentindemetz
  • fix: connection refused to PgDog if a database is down on proxy startup
  • fix: binary COPY crash with failed to fill whole buffer, caused by incorrect buffering of partial packets
  • fix: segfault in pg_query deparse_raw caused by empty C strings
  • fix: LISTEN/NOTIFY/UNLISTEN were blocked in session mode if pub_sub_channel_size was set to 0 by @mnbbrown
  • fix: transactions were incorrectly buffered in session mode and swallowed in transaction mode if advisory locks were used
  • fix: sending partial requests to backend after abrupt client disconnect, causing server connections to be stuck in ClientRead and active state
  • fix: exclude_primary should read from primary if there are no replicas @mijoharas
  • fix: add more params to the ignore list, like is_superuser, which caused errors when clients modified them with SET
  • chore: use OUT_DIR for autogenerated files, add bindings.rs to .gitignore @mijoharas

New Contributors

Full Changelog: v0.1.30...v0.1.31

v0.1.30

19 Feb 18:18
c316280

Choose a tag to compare

What's Changed

BREAKING: user settings take priority

User settings in users.toml now take priority over database settings in pgdog.toml. This was the opposite previously. For example:

users.toml

[[users]]
name = "pgdog"
database = "prod"
pool_size = 20

pgdog.toml

[general]
default_pool_size = 10

[[databases]]
name = "prod"
host = "127.0.0.1"
pool_size = 25

The connection pool for user pgdog will be 20.

🙏 @mijoharas

Changelog

  • feat: support OFFSET in cross-shard SELECT queries
  • feat: support for plugin API versioning @meskill
  • fix: incorrect error handling when queries are pipelined (psycopg, Sequelize, etc.)
  • feat: client_connection_recovery defaults to drop
  • refactor: make schema serializable for Enterprise Edition integration
  • feat: schema fetches foreign keys to support tables without sharding keys

New Contributors

Full Changelog: v0.1.29...v0.1.30

v0.1.29

12 Feb 15:37

Choose a tag to compare

What's Changed

  • feat: expose default_pool_size / pool_size, prepared_statements_limit and query_cache_limit as Prometheus metrics @Adi-Goll
  • feat: support cross-shard LIMIT (but not OFFSET, yet)
  • feat: support multiple SET statements in one query
  • feat: add client_connection_recovery setting which allows to close client connections that have received a checkout timeout / all replicas down error from PgDog
  • fix: race condition in Sequelize (Bind, Exexute, Flush, Sync) that caused record creation to be acknowledged before transaction committed in Postgres
  • fix: don't attempt to recover server connections that have received partial client requests (hard to determine state of connection)
  • fix: handle PortalSuspended message correctly
  • chore: Prisma, Sequelize tests
  • fix: place Sync into its own ClientRequest in spliced requests (Java driver)

New Contributors

Full Changelog: v0.1.28...v0.1.29

v0.1.28

05 Feb 16:30
943b652

Choose a tag to compare

What's Changed

  • fix: correctly handle INTEGER to BIGINT conversion during schema-sync by mutating table definitions instead of appending ALTER TABLE statements, and handle partitioned tables correctly
  • fix: average calculation in SHOW STATS for reads and writes stats
  • feat: make resharding COPY format configurable (text or binary)
  • feat: add TIMESTAMP/TIMESTAMPTZ support for aggregates (max(), min())
  • fix: parsing (de)serialization for composite types that cross a CopyData boundary during data-sync
  • fix: confusing TLS connection icon in logs (was open, now it's locked) @bzp2010
  • feat: automatically reload config (incl. schema) after DDL in a sharded cluster (single pgdog node, local dev/staging only)
  • fix: omnishard write fan-out is opaque now, returns rows changed from one shard only, while mutating rows everywhere; necessary for compatibility with Postgres behavior
  • feat: [[omnisharded_tables]] takes priority over [[sharded_tables]] in pgdog.toml
  • feat: add kind = "default" for for list-based sharding to mimic Postgres partitions behavior
  • fix: apply query_timeout to entire client/server exchange instead of just server responses (prevents TCP black holes)

New Contributors

Full Changelog: v0.1.27...v0.1.28

v0.1.27

30 Jan 16:47

Choose a tag to compare

What's Changed

  • feat: allow [[users]] to specify multiple databases (or all databases for admin users)
  • feat: handle INSERT ... SELECT for one row in sharded databases
  • feat: support INSERT without column names, using schema inference
  • feat: automatically inject pgdog.unique_id() if a BIGINT PRIMARY KEY isn't specified in INSERT statement. ORMs like ActiveRecord do this, making them work out of the box.
  • feat: add read/write query per-pool statistics (Prometheus and SHOW STATS)
  • chore: add Enterprise Edition hooks for the query parser
  • feat: rewrite INTEGER to BIGINT during schema-sync if its a primary key (supports foreign key references too)
  • feat: make how we treat system catalogs like pg_database configurable

Full Changelog: v0.1.26...v0.1.27