Search Postgresql Archives

Re: DDL support for logical replication

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Thu, Oct 10, 2019 at 3:09 PM Lev Kokotov <lev.kokotov@xxxxxxxxx> wrote:
Hi Miles,

One issue is keeping the subscriber and the publisher schema identical. Running migrations on both the publisher and subscriber does not seem atomic to me, therefore I don't have a way to enforce consistency between the two. The use case is simple: schemas change all the time, and keeping two databases (or more!) in sync manually is tough.

We had this requirement as well and this is why I wrote pgl_ddl_deploy on top of pglogical to handle the issue.  It's by no means an all-encompassing solution, but it's worked really well for us.  It only supports pglogical currently (which could be expanded for in-core logical... but we have not tried yet).

It basically uses event triggers, and inspecting what is being executed, as an idea of how to propagate DDL.

However, I am very interested in future of this feature for in-core logical replication in a much more natively-supported way.  As such, I have not heard anything for awhile.  Schema mapping for logical replication is another feature we really would want, and would also very much relate to DDL replication.  @Alvaro Herrera did a lot of great work on support for in-core DDL replication a few years back.  Here is that thread: https://postgr.es/m/CACACo5QQuAV+n4Gi+YA1JF_a+QenR6SJuP8CYdPSrXKa+FHS3A@xxxxxxxxxxxxxx

Thanks,
Jeremy


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Postgresql Jobs]     [Postgresql Admin]     [Postgresql Performance]     [Linux Clusters]     [PHP Home]     [PHP on Windows]     [Kernel Newbies]     [PHP Classes]     [PHP Books]     [PHP Databases]     [Postgresql & PHP]     [Yosemite]

  Powered by Linux