Sign inSign up

pt9912/pg-change-feed

By pt9912

•Updated 7 days ago

Durable change feeds for PostgreSQL, powered by logical replication.

Image
Message queues
Databases & storage
Monitoring & observability
1

1.6K

pt9912/pg-change-feed repository overview

⁠PG Change Feed

English | Deutsch⁠

Durable change feeds for PostgreSQL, powered by logical replication.

Source & issues: github.com/pt9912/pg-change-feed⁠

⁠What is PG Change Feed?

PG Change Feed provides persistent change feeds for existing PostgreSQL tables. It targets applications and integrations that need to consume changes reliably and independently, without having to process PostgreSQL WAL or the logical replication protocol themselves.

⁠What can I do today?

Everything below is available end-to-end, real-world tested — via environment variables, docker compose/make and SQL, with no graphical interface.

AreaWhat it does
CaptureAttach a PostgreSQL source via logical replication; (de)activate tables via SQL administration (cdc.enable_table/disable_table) or CDC_TABLES live; exclude individual columns from capture; store changes (INSERT/UPDATE/DELETE) transactionally and durably; detect schema changes on captured tables.
ReadingRead captured changes via SQL (cdc.changes) — or through one of four delivery paths: HTTP/JSON API, gRPC stream, Server-Sent Events or NATS (wake-up signal or full change content, table-granular).
ConsumersRegister multiple independent consumers, acknowledge and resume their position — duplicates are preferred over silent gaps.
RetentionRun time- and consumer-based retention, surface blocking consumers before they prevent deletion.
OperationsQuery operational status, CLI diagnostics, metrics and WAL lag; push metrics to an OpenTelemetry collector via OTLP/HTTP.
SecurityEnforce role-specific access rights (cdc_capture/cdc_admin/cdc_reader, least privilege, no user accounts of its own); protect the HTTP and gRPC APIs with API tokens per class (several valid tokens at once, so tokens can be rotated without downtime) and serve them over TLS.
DistributionAvailable as an OCI image for linux/amd64 and linux/arm64 (GHCR and Docker Hub, identical digest); the HTTP API, gRPC stream, SSE stream, and NATS full-content stream are also available as an official C# client library (PgChangeFeed.Client⁠ on NuGet.org), the same four delivery paths as an official Python client library (pgchangefeed⁠ on PyPI), and as an official Kotlin client library (pgchangefeed-kotlin on Cloudsmith and GitHub Packages).

Details and examples for each access path (Go, C#, Kotlin) are in the user manual⁠; the full scope of requirements and acceptance criteria is in spec/lastenheft.md⁠.

See:

⁠Why PG Change Feed?

PostgreSQL provides powerful CDC foundations with WAL, logical decoding and logical replication, but no general-purpose, persistent CDC abstraction with change history, stable positions, independent consumers and retention. PG Change Feed closes that gap without requiring a new database, a message broker, or changes to the source application.

⁠Core idea

PostgreSQL WAL → durable change feed → independent consumers.

A source position is only acknowledged after its associated changes have been stored durably. In failure scenarios, possible duplicates are preferred over silent gaps.

⁠What makes it trustworthy?

⁠License

MIT — see LICENSE⁠.

Tag summary

Content type

Image

Digest

sha256:97c68c406…

Size

7.9 MB

Last updated

7 days ago

docker pull pt9912/pg-change-feed