Skip to content

Releases: pgdogdev/pgdog

v0.1.38

24 Apr 21:24
1213bcc

Choose a tag to compare

What's Changed

  • feat: allow using SCRAM hash in users.toml as password_hash, if using server_auth = "rds_iam"; no passwords stored in any pgdog config file anymore
  • feat: add retries for COPY_DATA command (used in resharding); allows to retry long-running COPY operations instead of failing @meskill
  • feat: server_auth with Microsoft Workload Identity @MagicAbdel
  • feat: parse query comments using custom, faster parser; speed up the parser by 50%, 15% TPS improvement across the board when using simple protocol (e.g. Rails with prepared_statements: false)
  • fix: support servers that don't allow query cancellation (e.g., chaining RDS Proxy and PgDog now works)
  • fix: crashes in edge cases when query_parser_engine = "pg_query_raw"
  • feat: add max_pool_size, alias for default_pool_size (and pool_size)
  • fix: re-initialize pub/sub channel after failover
  • fix: add proper handling for pool restarts during resharding @meskill

New Contributors

Full Changelog: v0.1.37...v0.1.38

v0.1.37

16 Apr 16:36
4393ab2

Choose a tag to compare

What's Changed

  • fix: add bounds checks to some buffer accesses by @jaggederest
  • fix: ProtocolOutOfSync error
  • fix: count(*) in query broke CTE write check
  • fix: return ProtocolViolation instead of syntax error in admin DB; makes tools like pgcli work out of the box
  • feat: support multiple user/server passwords; supports zero-downtime password rotation
  • feat: handle SET in single-primary / only replicas configuration automatically
  • feat: add regex parser trigger to minimize parsing when not needed
  • feat: add parallel copy override for speeding up table copy during resharding
  • feat: add log throttle, to suppress duplicative logs during error storms
  • feat: detect advisory locks with regex
  • feat: support arrays as aggregate targets in cross-shard queries @jaggederest

Full Changelog: v0.1.36...v0.1.37

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