Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is logical replication using pglogical possible with timescaleDB?

I set up a fully functional logical replication of multiple masters to one slave.

As soon as I convert any of the replicated tables to timescaleDB's hypertable, the replication stops working - only the structure is replicated, but no data.

Is it possible to use timescaleDB together with pglogical? Would it be possible to use PostgreSQL 10 and its in-built logical replication abilities?

My guess is, that logical replication doesn't make sense in the context of tables consisting of virtual chunks.

like image 545
Tom Avatar asked Feb 07 '18 16:02

Tom


People also ask

How does logical replication work in PostgreSQL?

Logical replication uses a publish and subscribe model with one or more subscribers subscribing to one or more publications on a publisher node. Subscribers pull data from the publications they subscribe to and may subsequently re-publish data to allow cascading replication or more complex configurations.

What is Pglogical?

0, the next generation in logical replication for PostgreSQL. Implemented entirely as a PostgreSQL extension, pglogical is a logical replication system that serves as a highly efficient method of replicating data as an alternative to physical replication.


1 Answers

No.

To our knowledge, PG10's logical replication will not work with hypertables, because it actually doesn't replicate DDL commands, and instead just does a pub/sub on the data.
- Mike Freedman, CTO TimescaleDB (04.04.2019)

More info: https://github.com/timescale/timescaledb/issues/1138#issuecomment-479674594

like image 179
Tim Menapace Avatar answered Oct 02 '22 06:10

Tim Menapace