Documentation

Changelog

Notable changes to pg-fluent. Source of truth: CHANGELOG.md.

0.5.0 — 2026-12-05

Breaking

  • Error details/hint now use null when absent (PostgREST-compatible wire shape) instead of empty strings.
  • Executor.stream() accepts an optional AbortSignal parameter (custom executor implementations must update their signature).
  • @opentelemetry/api peer range widened to ^1.9.0.

Added

  • Streaming reads now honor request abort/timeout signals.
  • Read replicas can be configured on single/top-level connection configs (replicas).
  • GitHub Packages mirror publish is gated on successful CI and verifies tag/version.
  • Gen-types supports overloaded RPC signatures and aligns OUT/INOUT arguments.

Fixed

  • SQL injection hardening for COPY table identifiers; COPY now destroys pooled connections on non-completed failures and closes async iterators.
  • Classified-shaped errors are redacted before responses; observability/log hooks are fail-safe and redact error messages.
  • Planner/parser fixes: isdistinct null/boolean handling, plan-only related-order resolution, generated-column rejection for simple insert/PATCH, dotted JSON-path order parsing, and non-count * aggregate rejection.
  • Adapter/exec fixes: abort checks after pool connect, timeout/abort for max-affected/tx=rollback/EXPLAIN paths, safer savepoint rollback handling, and per-call db.unsafe() opt-in.
  • Router/listen/schema fixes: stream replica failover, read-your-writes refresh after transactions, subscribe/listen connect-failure handling, stop/connect race hardening, schema PK TOCTOU handling.
  • Response fixes: counted PATCH/DELETE minimal Content-Range, CSV/GeoJSON non-array body guard, CSV formula neutralization on export, and missing HTTP status text mappings.
  • CLI/gen-types fixes: redacted connection-string errors, unique-index one-to-one detection ignores partial/include-only indexes.

0.4.2 — 2026-12-05

Added

  • PostgreSQL 19 support, including integration coverage in CI.

Changed

  • Bumped @supabase/postgrest-js to 2.120.0 and refreshed transitive dependencies.

Fixed

  • Resolved npm audit findings for cross-spawn and minimatch via updated overrides.

0.4.0 — 2026-11-29

Added

  • Schema cache: TTL, LRU eviction, stampede de-duplication, generation-aware refresh, explicit pg_catalog qualification.
  • LISTEN/NOTIFY: quoted channel names, deferred UNLISTEN, per-channel re-LISTEN retries, NOTICE events, safe callback draining on stop().
  • Expanded unit coverage across planner/parser/cache/COPY/RPC/redaction/retries/observability/embeds/clients/LISTEN.

Changed

  • Upserts preserve omitted columns; batch inserts bind rows as a single JSONB parameter; embedded filters resolved for mutations.
  • RPC overload disambiguation by argument types; explicit handling for json[]/jsonb[], cast modifiers, scalar-result filters.
  • COPY validates formats/table names, escapes delimiters/control chars, applies backpressure, destroys connections after stream failures.
  • Transaction clients no longer share the parent's schema cache; close() invalidates derived clients consistently.

Fixed

  • Self-referential/composite-FK embeds, spread embeds, nested !inner filters, multi-level relation filters.
  • PATCH array validation, GROUP BY * with aggregates, text-search config validation.
  • Secret redaction in nested errors, awaited OTel span cleanup, retry classification, primary routing for NOTIFY, stream/connection cleanup.
  • Parser handling for JSON path escapes, quoted identifiers, CSV column names, list escapes, order modifiers, and resource names.

Earlier releases

See the full CHANGELOG.md on GitHub for 0.3.0, 0.2.1, 0.2.0, and earlier notes.