Skip to content
Search

Pgactive

lastmod 2025-07-18created 2025-07-181 edits

Active-active replication extension for Postgres

About

  • An active-active replication extension for PostgreSQL, built and released by AWS
  • When data writes and updates are needed on multiple PostgreSQL instances, it lets you build a structure where multiple instances can accept changes and replicate them concurrently, instead of the traditional active-standby model in which a single instance alone accepts changes
  • Suited to scenarios such as high-availability database setups across multiple regions, minimizing write latency, blue/green application updates, and bidirectional data migration
  • Uses logical replication to support conflict detection, write conflict resolution, format conversion for the target database, and more

Active-active replication concepts

  • Replication is a technology that synchronizes changes between databases
  • In the traditional PostgreSQL active-standby structure, only one instance accepts changes and the rest are read-only, so one place acts as the single source of data
  • pgactive provides an active-active replication topology, allowing data writes on multiple instances at the same time
  • This approach suits environments that need multiple write points, such as multi-region deployments or bidirectional migrations
  • The active-active model requires separate management of conflicts, latency, and some feature limitations

Core technology: logical replication

  • Logical replication sends data in a format that external systems can interpret
  • Logical replication makes it possible to implement various add-on features on the target database, such as conflict detection, write conflict resolution, and query conversion
  • PostgreSQL introduced basic logical replication in version 10 in 2017, but active-active replication requires additional features
  • Owing to PostgreSQL's design, such features can be developed and applied as extensions
  • The PostgreSQL development community is also gradually adding these features to the core project

See also

Favorite site

author Zer0 sitemap