Tuesday, November 21

News and Roadmap for BDR (Multi-master PostgreSQL)

Postgres-BDR is an open source project from 2ndQuadrant that provides multi-master features for PostgreSQL. We have pursued a joint strategy of providing both working code available now and also submitting the features into core PostgreSQL.

Postgres-BDR 1.0 runs on a variant distro of PG9.4. This is in Production now and receives regular maintenance and security updates. 2ndQuadrant will support this until 9.4 End of Life in December 2019.

One of the greatest achievements to come out of our work on BDR is the logical replication technology. Our engineers spent a considerable amount of energy to contribute the tech to PostgreSQL core and I feel especially proud that this is a headline feature of the upcoming PG10 release.

And Now BDR 2.0 … 

BDR 2.0 runs on community PG9.6 as an extension. 2ndQuadrant is making this available now to Support customers only. BDR 2.0 allows our customers to upgrade to PostgreSQL 9.6 while we work on some new BDR features to be made available in version 3.0, which will be released as open source.

BDR 3.0 will be available by Q1 2018, maybe earlier. We will be working with our customers to prioritize feature content and it already looks exciting. We expect BDR3 to be the main future development path and will be supported from its release for 5 years.

We will be submitting further enhancements of performance and robustness to logical replication into PG11. These are all important infrastructure features that will pave the path for inclusion of multi-master replication in PostgreSQL core.

Multi-master functionality from BDR 3.0 will be submitted as core patches to PG12 in 2018, allowing us to work hard towards getting it full function multi-master into core for Production use by Sept 2019 onwards. At that point the project will have taken us 7 years to complete integration.

19 Comments

  • Richard Zhang

    As we understand the current BDR 1.x and 2.x are the multiple master with asynchronous replication in the peer-to-peer mesh-up connection. For the multi-master BDR 3.0, will it have the SYNC replication as well as loosely-couple connection (using any communication protocol)? Could you elaborate what’s the exact meaning for the multi-master BDR 3.0? Thanks.

    • Yes, synchronous_commit will work with a variety of options to provide synchronous replication. It’s simply a function of the transport layer, so it still works with logical replication.

      • Richard Zhang

        Thanks for the quick reply. I understood that the “synchronous_commit” configuration option is available in the postgres 9.4 and can work with the 9.4 BDR asynchronous replication when it’s turned on. But, it can only provide two nodes synchronous_commit when cross the networking. I observed and confirmed this feature works in the 9.4 BDR cluster. But, it can’t provide N-node (I confirmed it with Craig Ringer).

        I wonder in the BDR 3.x release, whether this option is true for N-node synchronous_commit or not? I heard that this feature is very hard to implement.

          • Richard Zhang

            You mean, in the BDR 3.x release, it will have N-node synchronous_commit, right? For a 4-node BDR cluster, the commit on one node will be completed until all of other three nodes commit. Could you describe the “it all works now”? This is one of very important features we are looking for. Please clarify my understanding here. Thanks.

          • Richard, it’s necessary to be a bit more specific about what commit completion means.

            BDR2 on PostgreSQL 9.6 already supports n-nodes synchronous commit. It’s the same as PostgreSQL core’s feature for physical replication. The transaction commits on the originating node, and confirmation of commit to the client is delayed until all synchronous peer nodes have confirmed they have replayed the commit.

            It does not support distributed two phase commit. In this case, the commit is prepared on the originating node, all the peers replay the PREPARE TRANSACTION, and only then do any of them commit. This feature is planned as an option on top of the coming BDR 3. If it is important for your use case, please get in touch about options for funding development so you can influence the roadmap and development priorities.

          • Michael Vitale

            Interesting: two phased commit (2PC). So I’m guessing the goal is the “A” and “D”, not the “C” and “I” in ACID, correct? Only a distributed database like Postgres XL with a Global Lock Manager (GLM) can satisfy all ACID requirements. And then there is the issue of what kind of 2PC to implement, strict, etc. and how do we deal with the increasing likelihood of deadlocks…

  • Joe Wagner

    HI,

    I’m rather new to PostgreSQL and replication, so please forgive a newbee question.

    Can the publication/subscription functionality that is being developed for PostgreSQL 10 be used to maintain a set of multi-master databases?

    Thanks,
    Joe

  • Pavanteja

    Hi,

    Is ‘synchronous_comit’ option working for BDR 1.0 ? I mean to ask will the commit on one node of the BDR group will wait until all other nodes made that change visible?

    Is postgreSQL 10 coming up with an native Master/Master Clustering solution(shared disk)? Eager to know about these…

    Thanks,
    PavanTeja Achanta

    • Yes, synchronous commit works on BDR 1.0 – and on in-core logical replication in PostgreSQL 10 too.

      PostgreSQL 10 definitely will not have native MM clustering, shared-disk or replication wise. We continue to work on getting more functionality related to MM replication into PostgreSQL. I am not aware of anyone working on shared-disk based clustering for PostgreSQL.

        • Pavanteja

          I have a doubt I did a 2-node BDR set up. But the database size on the both the nodes is slightly varying around 58MB. But both the node status are running and BDR is active on both nodes.

          Is this a serious issue to consider regarding performance aspects? And will BDR have any performance overhead caused to the servers in terms of network/CPU etc ?

Leave a Reply

Your email address will not be published. Required fields are marked *