PgDog features
PgDog contains multiple foundational and unique features which make it a great choice for modern PostgreSQL deployments.
Most features are configurable and can be toggled on/off and tuned to fit your environment. Experimental features are marked as such, and users are advised to test them before deploying to production.
Foundational features like load balancing, health checks, and query routing have been battle-tested and work well in production.
Summary
Short summary of currently implemented features below.
| Feature | Description |
|---|---|
| Load balancer | Distribute SELECT queries evenly between replicas. Separate reads from writes, allowing applications to connect to a single endpoint. |
| Health checks | Check databases are up and running. Broken databases are blocked from serving queries. |
| Transaction mode | Multiplex PostgreSQL server connections between thousands of clients. |
| Hot reload | Update configuration at runtime without restarting the proxy. |
| Sharding | Automatic query routing and data migration between nodes to scale PostgreSQL horizontally. Schema management, distributed transactions. |
| Prepared statements | Support for Postgres named prepared statements in transaction mode. |
| Plugins | Pluggable libraries to add functionality to PgDog at runtime, without recompiling code. |
| Authentication | Support for various PostgreSQL user authentication mechanisms, like SCRAM. |
| Session mode | Compatibility mode with direct PostgreSQL connections. |
| Metrics | Real time reporting, including Prometheus/OpenMetrics and an admin database. |
| Mirroring | Copy queries from one database to another in the background. |
| Pub/Sub | Support for LISTEN/NOTIFY in transaction mode. |
| Encryption | TLS encryption for client and server connections. |
OS support
PgDog doesn't use any OS-specific features and should run on all systems supported by the Rust compiler, e.g. Linux (x86 and ARM64), Mac OS, and Windows.