Open-Awesome
CategoriesAlternativesStacksSelf-HostedExplore
Open-Awesome

© 2026 Open-Awesome. Curated for the developer elite.

TermsPrivacyAboutGitHubRSS
  1. Home
  2. Database Tools
  3. PGDeltaStream

PGDeltaStream

Apache-2.0Go

A Golang webserver that streams Postgres logical replication changes at-least-once over WebSockets.

GitHubGitHub
257 stars16 forks0 contributors

What is PGDeltaStream?

PGDeltaStream is a stateless Go service that streams PostgreSQL table changes in real-time over WebSockets using PostgreSQL's logical decoding feature. It provides at-least-once delivery guarantees by allowing clients to take a snapshot of current data and then stream subsequent changes, with the ability to acknowledge offsets to resume from the last consumed position.

Target Audience

Developers and engineers building real-time applications, data pipelines, or event-driven systems that need reliable, low-latency change data capture (CDC) from PostgreSQL databases. It is particularly useful for those implementing custom replication solutions or streaming database events to external services.

Value Proposition

Developers choose PGDeltaStream for its simplicity and reliability as a reference implementation of PostgreSQL logical replication in Go, offering a straightforward way to stream database changes with at-least-once delivery without managing persistent state. Its stateless design and built-in snapshot initialization simplify deployment and ensure no event data is lost during client reconnections.

Overview

Streaming Postgres logical replication changes atleast-once over websockets

Use Cases

Best For

  • Building real-time dashboards that reflect live PostgreSQL data changes.
  • Implementing custom change data capture (CDC) pipelines for data synchronization.
  • Streaming database events to external services or microservices over WebSockets.
  • Creating audit logs or activity feeds based on PostgreSQL table modifications.
  • Developing event-driven architectures that react to database changes.
  • Learning how to implement PostgreSQL logical replication in Go as a reference boilerplate.

Not Ideal For

  • Production systems requiring concurrent streaming from multiple replication slots or databases.
  • Teams needing built-in change filtering, transformation, or encryption for data streams.
  • Environments where minimal database configuration is critical, as it requires Postgres logical replication setup and wal2json.

Pros & Cons

Pros

Direct Logical Decoding

Leverages Postgres' built-in logical replication to stream WAL changes in real-time over WebSockets, providing low-latency data capture directly from the database.

At-Least-Once Delivery

Guarantees no event loss by using LSN acknowledgment, allowing clients to resume streaming from the last consumed position after reconnections.

Snapshot Initialization

Includes an HTTP endpoint to fetch initial table data from the replication slot's snapshot, simplifying state synchronization before streaming changes.

Stateless Deployment

Runs as a standalone service without persistent state, making deployment straightforward and reducing operational overhead.

Cons

Single-Session Limitation

Designed for only one replication slot at a time; any new init call deletes the existing slot, preventing concurrent streaming or multi-tenant use.

Basic Feature Set

As a reference boilerplate, it lacks advanced CDC features like change filtering, batching, or built-in security, requiring client-side or custom modifications.

Setup Complexity

Requires non-trivial Postgres configuration (wal_level = logical, max_replication_slots) and wal2json installation, which can be a barrier for less experienced users.

Frequently Asked Questions

Quick Stats

Stars257
Forks16
Contributors0
Open Issues5
Last commit8 years ago
CreatedSince 2018

Tags

#write-ahead-log#logical-replication#postgres#change-data-capture#wal#postgresql#golang#go#real-time#websockets

Built With

P
PostgreSQL
G
Golang
D
Docker

Included in

Database Tools5.1k
Auto-fetched 1 day ago

Related Projects

LitestreamLitestream

Streaming replication for SQLite.

Stars13,666
Forks361
Last commit2 days ago
pgsyncpgsync

Sync data from one Postgres database to another

Stars3,452
Forks218
Last commit5 months ago
repmgrrepmgr

A lightweight replication manager for PostgreSQL (Postgres)

Stars1,699
Forks263
Last commit2 months ago
dtledtle

Distributed Data Transfer Service for MySQL

Stars559
Forks136
Last commit2 years ago
Community-curated · Updated weekly · 100% open source

Found a gem we're missing?

Open-Awesome is built by the community, for the community. Submit a project, suggest an awesome list, or help improve the catalog on GitHub.

Submit a projectStar on GitHub