A low-level, high-performance PostgreSQL logical replication client implemented directly on top of the PostgreSQL wire protocol (pgwire). This crate is designed for CDC, change streaming, and WAL replay systems that require explicit control over replication state, deterministic restart behavior, and minimal runtime overhead. pgwire-replication intentionally avoids libpq , tokio-postgres , and other higher-level PostgreSQL clients for the replication path. It interacts with a Postgres instance directly and relies on START_REPLICATION ... LOGICAL ... and the built-in pgoutput output plugin. pgwire-replication exists to provide: a direct pgwire implementation for logical replication for logical replication explicit, user-controlled LSN start and stop semantics predictable feedback and backpressure behavior clean integration into async systems and coordinators This crate was originally extracted from the Deltaforge CDC project and is maintained independently. Installation Add to your Cargo.toml : [ dependencies ] pgwire-replication = " 0.1 " Or with specific features: [ dependencies ] pgwire-replication = { version = " 0.1 " , default-features = false , features = [ " tls-rustls " ] } Requirements Rust 1.88 or later PostgreSQL 15+ with logical replication enabled (older versions will probably work too) Features Logical replication using the PostgreSQL wire protocol pgoutput logical decoding support (transport-level) logical decoding support (transport-level) Explicit LSN seek ( start_lsn ) ) Bounded replay ( stop_at_lsn ) ) Periodic standby status updates Keepalive handling Tokio-based async client SCRAM-SHA-256 and MD5 authentication TLS/mTLS support (via rustls) Designed for checkpoint and replay-based systems This crate intentionally does not provide: A general-purpose SQL client Automatic checkpoint persistence Exactly-once semantics Schema management or DDL interpretation Full pgoutput decoding into rows or events These responsibilities belong in higher layers. Bas...
First seen: 2026-01-16 12:20
Last seen: 2026-01-16 17:21