Hi Hou-san, here are my review comments for the patch v15-0001:
==
1. Commit Message
CREATE/ALTER/DROP TABLE (*)
At first, I thought "(*)" looks like a SQL syntax element.
SUGGESTION:
CREATE/ALTER/DROP TABLE - - Note #1, Note #2
...
Note #1 – blah blah
Note #2 – yada yada
==
2. src/
FYI, I found that the v14-0001 patch does not currently apply [1]. Can
you please rebase it?
--
[1] http://cfbot.cputube.org/patch_38_3595.log
Kind Regards,
Peter Smith.
Fujitsu Australia
On Sat, Jul 23, 2022 at 2:49 AM Zheng Li wrote:
>
> Hello,
>
> Here is a patch that supports replication of global object commands,
> these include ROLE statements, database statements and tablespace statements.
> The patch should be applied on top of the v13 DDL replication patch set that
> ZJ Ho
On Sat, Jul 23, 2022 at 11:33 AM Joe Conway wrote:
>
> On 7/22/22 17:18, Zheng Li wrote:
> > Here is a patch that supports replication of global object commands,
> > these include ROLE statements, database statements and tablespace
> > statements.
> > The patch should be applied on top of the v13
On 7/22/22 17:18, Zheng Li wrote:
Here is a patch that supports replication of global object commands,
these include ROLE statements, database statements and tablespace statements.
The patch should be applied on top of the v13 DDL replication patch set that
ZJ Hou sent in the previous email.
Glo
Hello,
Here is a patch that supports replication of global object commands,
these include ROLE statements, database statements and tablespace statements.
The patch should be applied on top of the v13 DDL replication patch set that
ZJ Hou sent in the previous email.
Global objects commands are dif
Here are some review comments for the patch v11-0001:
==
1. Commit message
This provides base for logical replication of DDL statements. Currently,
this provides support for:
SUGGESTION
This provides a base for logical replication of DDL statements. Currently,
the patch has support for:
==
On Sat, Jul 2, 2022 at 8:51 AM Amit Kapila wrote:
>
> On Fri, Jul 1, 2022 at 10:22 PM vignesh C wrote:
> >
> > On Wed, Jun 29, 2022 at 3:25 PM houzj.f...@fujitsu.com
> > wrote:
> > >
> >
> > Thanks for the updated patch.
> > Few comments on 0002 patch:
> > 1) When we create a subscription for a
On Fri, Jul 1, 2022 at 10:22 PM vignesh C wrote:
>
> On Wed, Jun 29, 2022 at 3:25 PM houzj.f...@fujitsu.com
> wrote:
> >
>
> Thanks for the updated patch.
> Few comments on 0002 patch:
> 1) When we create a subscription for a publication with the existing
> default PUBLISH parameter having defaul
On Wed, Jun 29, 2022 at 3:25 PM houzj.f...@fujitsu.com
wrote:
>
> On Wednesday, June 29, 2022 11:07 AM Amit Kapila
> wrote:
> >
> > On Tue, Jun 28, 2022 at 5:43 PM Amit Kapila
> > wrote:
> > >
> > > 5.
> > > +static ObjTree *
> > > +deparse_CreateStmt(Oid objectId, Node *parsetree)
> > > {
> >
On Thu, Jun 30, 2022 at 11:44 AM Amit Kapila wrote:
>
> On Wed, Jun 29, 2022 at 3:17 PM houzj.f...@fujitsu.com
> wrote:
> >
> > On Tuesday, June 28, 2022 11:27 AM Amit Kapila
> > >
> > > +1. I think it doesn't make sense to replicate temporary tables.
> > > Similarly, we don't need to replicate
On Wed, Jun 29, 2022 at 3:17 PM houzj.f...@fujitsu.com
wrote:
>
> On Tuesday, June 28, 2022 11:27 AM Amit Kapila
> > On Sun, Jun 26, 2022 at 11:47 PM Alvaro Herrera
> > wrote:
> > >
> > > However, that would still replicate a command that involves a
> > > temporary table, which perhaps should no
On Wed, Jun 29, 2022 at 3:24 PM houzj.f...@fujitsu.com
wrote:
>
> On Wednesday, June 29, 2022 11:07 AM Amit Kapila
> wrote:
> >
> > On Tue, Jun 28, 2022 at 5:43 PM Amit Kapila
> > wrote:
> > >
> > > 5.
> > > +static ObjTree *
> > > +deparse_CreateStmt(Oid objectId, Node *parsetree)
> > > {
> >
On Tuesday, June 28, 2022 11:27 AM Amit Kapila
> On Sun, Jun 26, 2022 at 11:47 PM Alvaro Herrera
> wrote:
> >
> > On 2022-Jun-22, vignesh C wrote:
> >
> > > 1) Creation of temporary table fails infinitely in the subscriber.
> > > CREATE TEMPORARY TABLE temp1 (a int primary key);
> > >
> > > The a
On Tue, Jun 28, 2022 at 5:43 PM Amit Kapila wrote:
>
> 5.
> +static ObjTree *
> +deparse_CreateStmt(Oid objectId, Node *parsetree)
> {
> ...
> + tmp = new_objtree_VA("TABLESPACE %{tablespace}I", 0);
> + if (node->tablespacename)
> + append_string_object(tmp, "tablespace", node->tablespacename);
>
On Tue, Jun 21, 2022 at 5:49 PM houzj.f...@fujitsu.com
wrote:
>
> On Monday, June 20, 2022 11:32 AM houzj.f...@fujitsu.com
> wrote:
> >
> > On Saturday, June 18, 2022 3:38 AM Zheng Li wrote:
> > > On Wed, Jun 15, 2022 at 12:00 AM Amit Kapila
> > > wrote:
> > > >
> > > > On Wed, Jun 15, 2022 at
On Tue, Jun 21, 2022 at 5:49 PM houzj.f...@fujitsu.com
wrote:
>
> On Monday, June 20, 2022 11:32 AM houzj.f...@fujitsu.com
> wrote:
> >
>
> Attach the new version patch set which added support for CREATE/DROP/ATER
> Sequence and CREATE/DROP Schema ddl commands which are provided by Ajin
> Cheria
On Sun, Jun 26, 2022 at 11:47 PM Alvaro Herrera wrote:
>
> On 2022-Jun-22, vignesh C wrote:
>
> > 1) Creation of temporary table fails infinitely in the subscriber.
> > CREATE TEMPORARY TABLE temp1 (a int primary key);
> >
> > The above statement is converted to the below format:
> > CREATE TEMPOR
On 2022-Jun-22, vignesh C wrote:
> 1) Creation of temporary table fails infinitely in the subscriber.
> CREATE TEMPORARY TABLE temp1 (a int primary key);
>
> The above statement is converted to the below format:
> CREATE TEMPORARY TABLE pg_temp.temp1 (a pg_catalog.int4 ,
> CONSTRAINT temp1_pke
On Fri, Jun 24, 2022 at 8:10 AM Masahiko Sawada wrote:
>
> On Thu, Jun 23, 2022 at 7:00 PM Amit Kapila wrote:
> >
> > On Wed, Jun 22, 2022 at 11:09 AM Masahiko Sawada
> > wrote:
> > >
> > > I've attached a WIP patch for adding regression tests for DDL deparse.
> > > The patch can be applied on
On Thu, Jun 23, 2022 at 7:00 PM Amit Kapila wrote:
>
> On Wed, Jun 22, 2022 at 11:09 AM Masahiko Sawada
> wrote:
> >
> > I've attached a WIP patch for adding regression tests for DDL deparse.
> > The patch can be applied on
> > v9-0001-Functions-to-deparse-DDL-commands.patch Hou recently
> > sub
On 2022-Jun-15, houzj.f...@fujitsu.com wrote:
> On Wednesday, June 15, 2022 8:14 AM Zheng Li wrote:
> > How does the deparser deparses CREATE FUNCTION STATEMENT? Will it
> > schema qualify
> > objects inside the function definition?
>
> The current deparser doesn't schema qualify objects inside
On Wed, Jun 22, 2022 at 11:09 AM Masahiko Sawada wrote:
>
> I've attached a WIP patch for adding regression tests for DDL deparse.
> The patch can be applied on
> v9-0001-Functions-to-deparse-DDL-commands.patch Hou recently
> submitted[1]. The basic idea is to define the event trigger to deparse
>
On Thursday, June 23, 2022 6:22 AM Zheng Li wrote:
Hi,
>
> > Here are some points in my mind about the two approaches discussed here.
> >
> > 1) search_patch vs schema qualify
> >
> > Again, I still think it will bring more flexibility and security by
> > schema qualify the objects in DDL comma
> Here are some points in my mind about the two approaches discussed here.
>
> 1) search_patch vs schema qualify
>
> Again, I still think it will bring more flexibility and security by schema
> qualify the
> objects in DDL command as mentioned before[1].
I wonder what security concerns you have?
On Tue, Jun 21, 2022 at 5:49 PM houzj.f...@fujitsu.com
wrote:
>
> On Monday, June 20, 2022 11:32 AM houzj.f...@fujitsu.com
> wrote:
> >
> > On Saturday, June 18, 2022 3:38 AM Zheng Li wrote:
> > > On Wed, Jun 15, 2022 at 12:00 AM Amit Kapila
> > > wrote:
> > > >
> > > > On Wed, Jun 15, 2022 at
On Wed, Jun 15, 2022 at 1:00 PM Amit Kapila wrote:
>
> On Wed, Jun 15, 2022 at 5:44 AM Zheng Li wrote:
> >
> >
> > While I agree that the deparser is needed to handle the potential
> > syntax differences between
> > the pub/sub, I think it's only relevant for the use cases where only a
> > subset
On Saturday, June 18, 2022 3:38 AM Zheng Li wrote:
> On Wed, Jun 15, 2022 at 12:00 AM Amit Kapila
> wrote:
> >
> > On Wed, Jun 15, 2022 at 5:44 AM Zheng Li wrote:
> > >
> > >
> > > While I agree that the deparser is needed to handle the potential
> > > syntax differences between the pub/sub, I t
On Wednesday, June 15, 2022 8:14 AM Zheng Li wrote:
>
> > Thanks for providing this idea.
> >
> > I looked at the string that is used for replication:
> >
> > """
> > {ALTERTABLESTMT :relation {RANGEVAR :schemaname public :relname foo
> > :inh true :relpersistence p :alias <> :location 12} :cmds
On Wed, Jun 15, 2022 at 5:44 AM Zheng Li wrote:
>
>
> While I agree that the deparser is needed to handle the potential
> syntax differences between
> the pub/sub, I think it's only relevant for the use cases where only a
> subset of tables in the database
> are replicated. For other use cases whe
> Thanks for providing this idea.
>
> I looked at the string that is used for replication:
>
> """
> {ALTERTABLESTMT :relation {RANGEVAR :schemaname public :relname foo
> :inh true :relpersistence p :alias <> :location 12} :cmds ({ALTERTABLECMD
> :subtype 0 :name <> :num 0 :newowner <> :def {COLUMN
On Sunday, June 12, 2022 2:46 PM Zheng Li wrote:
>
> > > > > > I've not looked at these patches in-depth yet but with this
> > > > > > approach, what do you think we can handle the DDL syntax
> > > > > > differences between major versions? DDL syntax or behavior
> > > > > > could be changed by fu
On Thu, Jun 9, 2022 at 5:14 PM houzj.f...@fujitsu.com
wrote:
>
> Hi,
>
> I did some research for one potential problem[1] mentioned earlier which is
> related
> to the function execution when replicating DDL.
>
> [1]> 4. Statements that have nondeterministic side effects (e.g., as caused
> > by t
On Thu, Jun 2, 2022 at 5:44 PM houzj.f...@fujitsu.com
wrote:
>
> The main idea of replicating the CREATE TABLE AS is that we deprase the CREATE
> TABLE AS into a simple CREATE TABLE(without subquery) command and WAL log it
> after creating the table and before writing data into the table and repli
On Fri, May 27, 2022 at 11:03 AM Amit Kapila wrote:
>
> On Fri, May 27, 2022 at 3:49 AM Zheng Li wrote:
> >
> > Hi Masahiko,
> >
> > > Thank you for updating the patches!
> > >
> > > I've not looked at these patches in-depth yet but with this approach,
> > > what do you think we can handle the DD
On Fri, May 27, 2022 at 7:19 AM Zheng Li wrote:
>
> Hi Masahiko,
>
> > Thank you for updating the patches!
> >
> > I've not looked at these patches in-depth yet but with this approach,
> > what do you think we can handle the DDL syntax differences between
> > major versions? DDL syntax or behavior
On Fri, May 27, 2022 at 3:49 AM Zheng Li wrote:
>
> Hi Masahiko,
>
> > Thank you for updating the patches!
> >
> > I've not looked at these patches in-depth yet but with this approach,
> > what do you think we can handle the DDL syntax differences between
> > major versions? DDL syntax or behavior
Hi Masahiko,
> Thank you for updating the patches!
>
> I've not looked at these patches in-depth yet but with this approach,
> what do you think we can handle the DDL syntax differences between
> major versions? DDL syntax or behavior could be changed by future
> changes and I think we need to som
On Sat, May 14, 2022 at 6:02 AM Zheng Li wrote:
>
> > > 4. The handling related to partition tables seems missing because, on
> > > the subscriber-side, it always creates a relation entry in
> > > pg_subscription_rel which won't work. Check its interaction with
> > > publish_via_partition_root.
>
> Now, say, the user has added a bar column with "ALTER TABLE foo ADD
> COLUMN bar double precision NOT NULL DEFAULT random();" If we compare
> with replication of DMLs like (UPDATE ddl_test SET bar = random();),
> the replication won't update rows with values (3 and 4) on subscriber
> as they don'
On Thu, Apr 14, 2022 at 7:45 PM Euler Taveira wrote:
>
> You should forbid it. Unless you can decompose the command into multiple SQL
> commands to make it a safe operation for logical replication.
>
> Let's say you want to add a column with a volatile default.
>
> ALTER TABLE foo ADD COLUMN bar d
On Wed, May 11, 2022 at 6:25 PM Masahiko Sawada wrote:
>
> On Wed, May 11, 2022 at 6:15 PM Amit Kapila wrote:
> >
> > On Wed, May 11, 2022 at 1:09 PM Masahiko Sawada
> > wrote:
> > >
> > > On Mon, May 9, 2022 at 6:05 PM Alvaro Herrera
> > > wrote:
> > > >
> > > >
> > > > The code in test_ddl_
On Wed, May 11, 2022 at 6:15 PM Amit Kapila wrote:
>
> On Wed, May 11, 2022 at 1:09 PM Masahiko Sawada wrote:
> >
> > On Mon, May 9, 2022 at 6:05 PM Alvaro Herrera
> > wrote:
> > >
> > > On 2022-May-08, Dilip Kumar wrote:
> >
> > >
> > > The code in test_ddl_deparse is a pretty lame start, not
On Wed, May 11, 2022 at 1:09 PM Masahiko Sawada wrote:
>
> On Mon, May 9, 2022 at 6:05 PM Alvaro Herrera wrote:
> >
> > On 2022-May-08, Dilip Kumar wrote:
>
> >
> > The code in test_ddl_deparse is a pretty lame start, not nearly good
> > enough by a thousand miles. My real intention was to have
On Mon, May 9, 2022 at 6:05 PM Alvaro Herrera wrote:
>
> On 2022-May-08, Dilip Kumar wrote:
>
> > On Sat, May 7, 2022 at 9:38 AM Amit Kapila wrote:
>
> > > I agree that it adds to our maintainability effort, like every time we
> > > enhance any DDL or add a new DDL that needs to be replicated, we
On Wed, May 11, 2022 at 1:01 AM Zheng Li wrote:
>
> > > > I agree that it adds to our maintainability effort, like every time we
> > > > enhance any DDL or add a new DDL that needs to be replicated, we
> > > > probably need to change the deparsing code. But OTOH this approach
> > > > seems to prov
> > > I agree that it adds to our maintainability effort, like every time we
> > > enhance any DDL or add a new DDL that needs to be replicated, we
> > > probably need to change the deparsing code. But OTOH this approach
> > > seems to provide better flexibility. So, in the long run, maybe the
> >
On Tue, May 10, 2022 at 4:59 PM Ajin Cherian wrote:
>
> On Fri, May 6, 2022 at 11:24 PM Amit Kapila wrote:
> > As we have hacked CreatePublication function for this POC, the
> > regression tests are not passing but we can easily change it so that
> > we invoke new functionality with the syntax pr
On Fri, May 6, 2022 at 11:24 PM Amit Kapila wrote:
> As we have hacked CreatePublication function for this POC, the
> regression tests are not passing but we can easily change it so that
> we invoke new functionality with the syntax proposed in this thread or
> with some other syntax and we shall
On Tue, May 10, 2022 at 12:32 PM Masahiko Sawada wrote:
>
> On Wed, Apr 13, 2022 at 6:50 PM Amit Kapila wrote:
> >
> > On Wed, Apr 13, 2022 at 2:38 PM Dilip Kumar wrote:
> > >
> > > On Tue, Apr 12, 2022 at 4:25 PM Amit Kapila
> > > wrote:
> > > >
> > > > > The *initial* DDL replication is a di
On Wed, Apr 13, 2022 at 6:50 PM Amit Kapila wrote:
>
> On Wed, Apr 13, 2022 at 2:38 PM Dilip Kumar wrote:
> >
> > On Tue, Apr 12, 2022 at 4:25 PM Amit Kapila wrote:
> > >
> > > > The *initial* DDL replication is a different problem than DDL
> > > > replication. The
> > > > former requires a sna
On 2022-May-08, Dilip Kumar wrote:
> On Sat, May 7, 2022 at 9:38 AM Amit Kapila wrote:
> > I agree that it adds to our maintainability effort, like every time we
> > enhance any DDL or add a new DDL that needs to be replicated, we
> > probably need to change the deparsing code. But OTOH this app
On Mon, May 9, 2022 at 12:46 PM Bharath Rupireddy
wrote:
>
> On Sun, May 8, 2022 at 12:39 PM Dilip Kumar wrote:
> >
> > On Sat, May 7, 2022 at 9:38 AM Amit Kapila wrote:
> > >
> > > On Fri, May 6, 2022 at 10:21 PM Zheng Li wrote:
> > > >
> > > > > Attached is a set of two patches as an attempt
On Sun, May 8, 2022 at 12:39 PM Dilip Kumar wrote:
>
> On Sat, May 7, 2022 at 9:38 AM Amit Kapila wrote:
> >
> > On Fri, May 6, 2022 at 10:21 PM Zheng Li wrote:
> > >
> > > > Attached is a set of two patches as an attempt to evaluate this
> > > > approach.
> > > >
> > >
> > > Thanks for explori
On Sat, May 7, 2022 at 9:38 AM Amit Kapila wrote:
>
> On Fri, May 6, 2022 at 10:21 PM Zheng Li wrote:
> >
> > > Attached is a set of two patches as an attempt to evaluate this approach.
> > >
> >
> > Thanks for exploring this direction.
> >
> > I read the deparsing thread and your patch. Here is
On Fri, May 6, 2022 at 10:21 PM Zheng Li wrote:
>
> > Attached is a set of two patches as an attempt to evaluate this approach.
> >
>
> Thanks for exploring this direction.
>
> I read the deparsing thread and your patch. Here is my thought:
> 1. The main concern on maintainability of the deparsing
> Attached is a set of two patches as an attempt to evaluate this approach.
>
> The first patch provides functions to deparse DDL commands. Currently,
> it is restricted to just a simple CREATE TABLE statement, the required
> code is extracted from one of the patches posted in the thread [1].
>
> T
> > >Another somewhat unrelated problem I see with this work is how to save
> > >recursion of the same command between nodes (when the involved nodes
> > >replicate DDLs). For DMLs, we can avoid that via replication origins
> > >as is being done in the patch proposed [1] but not sure how will we
>
Hello,
> You should forbid it. Unless you can decompose the command into multiple SQL
> commands to make it a safe operation for logical replication.
>
> Let's say you want to add a column with a volatile default.
>
> ALTER TABLE foo ADD COLUMN bar double precision DEFAULT random();
>
> If you rep
> > But then this could be true for DML as well right? Like after
> > replicating the function to the subscriber if we are sending the DML
> > done by function then what's the problem in DDL. I mean if there is
> > no design issue in implementing this then I don't think there is much
> > point in
> You should forbid it. Unless you can decompose the command into multiple SQL
> commands to make it a safe operation for logical replication.
>
> Let's say you want to add a column with a volatile default.
>
> ALTER TABLE foo ADD COLUMN bar double precision DEFAULT random();
>
> If you replicate t
On Thu, Apr 14, 2022, at 6:26 AM, Dilip Kumar wrote:
> I agree. But here the bigger question is what is the correct behavior
> in case of the Alter Table? I mean for example in the publisher the
> table gets rewritten due to the Access Method change then what should
> be the behavior of the subsc
On Fri, Apr 8, 2022 at 4:30 PM Amit Kapila wrote:
>
> On Tue, Mar 29, 2022 at 9:47 AM Dilip Kumar wrote:
> > >
> > > The idea is to force skipping any direct data population (which can
> > > potentially cause data inconsistency on the subscriber)
> > > in CREATE AS and SELECT INTO command on the
On Wed, Apr 13, 2022 at 2:38 PM Dilip Kumar wrote:
>
> On Tue, Apr 12, 2022 at 4:25 PM Amit Kapila wrote:
> >
> > > The *initial* DDL replication is a different problem than DDL
> > > replication. The
> > > former requires a snapshot to read the current catalog data and build a
> > > CREATE
> >
On Tue, Apr 12, 2022 at 4:25 PM Amit Kapila wrote:
>
> > The *initial* DDL replication is a different problem than DDL replication.
> > The
> > former requires a snapshot to read the current catalog data and build a
> > CREATE
> > command as part of the subscription process. The subsequent DDLs
On Wed, Apr 13, 2022 at 5:49 AM Zheng Li wrote:
>
> Hi,
>
> Here is the rebased new branch
> https://github.com/zli236/postgres/commits/ddl_replication
>
Thanks, but it would be good if you can share it in the patch form as
well unless you need to send patches too frequently. It is easier to
give
Hi,
Here is the rebased new branch
https://github.com/zli236/postgres/commits/ddl_replication
Regards,
Zheng
On Mon, Apr 11, 2022 at 11:01 PM Zheng Li wrote:
>
> >Even if this works, how will we make Alter Table statement work where
> >it needs to rewrite the table? There also I think we can face a
> >similar problem if we directly send the statement, once the table will
> >be updated due to the DDL stat
On Mon, Apr 11, 2022 at 6:16 PM Euler Taveira wrote:
>
> On Mon, Apr 11, 2022, at 2:00 AM, Amit Kapila wrote:
>
> On Thu, Apr 7, 2022 at 3:46 PM Amit Kapila wrote:
> >
> > On Wed, Mar 23, 2022 at 10:39 AM Japin Li wrote:
> >
> > 2. For DDL replication, do we need to wait for a consistent point o
> I'm planning to work on the initial DDL replication. I'll open a new thread as
> soon as I write a design for it. Just as an example, the pglogical approach is
> to use pg_dump behind the scenes to provide the schema [1]. It is a reasonable
> approach but an optimal solution should be an API to p
Hi Amit,
> Some initial comments:
> ===
> 1.
> +/*
> + * Write logical decoding DDL message into XLog.
> + */
> +XLogRecPtr
> +LogLogicalDDLMessage(const char *prefix, Oid roleoid, const char *message,
> + size_t size, bool transactional)
>
> I don't see anywhere the patch using a
Hi,
> > Good catch. The reason for having isTopLevel in the condition is
> > because I haven't decided if a DDL statement inside a PL should
> > be replicated from the user point of view. For example, if I execute a
> > plpgsql function or a stored procedure which creates a table under the hood,
>
On Mon, Apr 11, 2022, at 2:00 AM, Amit Kapila wrote:
> On Thu, Apr 7, 2022 at 3:46 PM Amit Kapila wrote:
> >
> > On Wed, Mar 23, 2022 at 10:39 AM Japin Li wrote:
> >
> > 2. For DDL replication, do we need to wait for a consistent point of
> > snapshot? For DMLs, that point is a convenient point t
On Fri, Apr 8, 2022 at 5:04 PM Alvaro Herrera wrote:
>
> On 2022-Apr-08, Amit Kapila wrote:
>
>
> > For runtime conditions, one of the things you have mentioned in that
> > thread is to add schema name in the statement at the required places
> > which this patch deals with in a different way by ex
On Thu, Apr 7, 2022 at 3:46 PM Amit Kapila wrote:
>
> On Wed, Mar 23, 2022 at 10:39 AM Japin Li wrote:
>
> 2. For DDL replication, do we need to wait for a consistent point of
> snapshot? For DMLs, that point is a convenient point to initialize
> replication from, which is why we export a snapsho
On Fri, Apr 8, 2022 at 7:34 AM Alvaro Herrera wrote:
> > For runtime conditions, one of the things you have mentioned in that
> > thread is to add schema name in the statement at the required places
> > which this patch deals with in a different way by explicitly sending
> > it along with the DDL
On 2022-Apr-08, Amit Kapila wrote:
> On Thu, Mar 17, 2022 at 3:36 AM Alvaro Herrera
> wrote:
> >
> > Did you see some old code I wrote towards this goal?
> > https://www.postgresql.org/message-id/20150215044814.gl3...@alvh.no-ip.org
> > The intention was that DDL would produce some JSON blob tha
On Thu, Mar 17, 2022 at 3:36 AM Alvaro Herrera wrote:
>
> Did you see some old code I wrote towards this goal?
> https://www.postgresql.org/message-id/20150215044814.gl3...@alvh.no-ip.org
> The intention was that DDL would produce some JSON blob that accurately
> describes the DDL that was run;
>
On Tue, Mar 29, 2022 at 9:47 AM Dilip Kumar wrote:
> >
> > The idea is to force skipping any direct data population (which can
> > potentially cause data inconsistency on the subscriber)
> > in CREATE AS and SELECT INTO command on the subscriber by forcing the
> > skipData flag in the intoClause o
On Tue, Mar 29, 2022 at 9:47 AM Dilip Kumar wrote:
>
> On Thu, Mar 24, 2022 at 11:24 PM Zheng Li wrote:
> >
> >
> > Good catch. The reason for having isTopLevel in the condition is
> > because I haven't decided if a DDL statement inside a PL should
> > be replicated from the user point of view. F
On Wed, Mar 23, 2022 at 10:39 AM Japin Li wrote:
>
> Thanks for fixing this. I rebase the patchset on current master (383f222119)
> and attach here for further review.
>
Some initial comments:
===
1.
+/*
+ * Write logical decoding DDL message into XLog.
+ */
+XLogRecPtr
+LogLogic
On Wed, Mar 23, 2022 at 4:09 PM Japin Li wrote:
>
>
> On Tue, 22 Mar 2022 at 04:56, Zheng Li wrote:
> > Hi Japin,
> >
> >> You should use a different user that has different length from your
> >> current one.
> >> For example:
> >>
> >> px@localhost$ make check-world
> >
> > This is fixe
On Thu, Mar 24, 2022 at 11:24 PM Zheng Li wrote:
>
> Hi Dilip,
>
> Thanks for the feedback.
>
> > > > > The table creation WAL and table insert WAL are available. The tricky
> > > > > part is how do we break down this command into two parts (a normal
> > > > > CREATE TABLE followed by insertions)
Hi Dilip,
Thanks for the feedback.
> > > > The table creation WAL and table insert WAL are available. The tricky
> > > > part is how do we break down this command into two parts (a normal
> > > > CREATE TABLE followed by insertions) either from the parsetree or the
> > > > WALs. I’ll have to dig
On Thu, Mar 24, 2022 at 3:32 PM Dilip Kumar wrote:
>
> On Mon, Mar 21, 2022 at 1:43 PM Dilip Kumar wrote:
> >
> > On Thu, Mar 17, 2022 at 2:47 AM Zheng Li wrote:
> > >
> > > Hi,
> > >
> > > >If you don't mind, would you like to share the POC or the branch for
> > > >this work?
> > >
> > > The P
On Mon, Mar 21, 2022 at 1:43 PM Dilip Kumar wrote:
>
> On Thu, Mar 17, 2022 at 2:47 AM Zheng Li wrote:
> >
> > Hi,
> >
> > >If you don't mind, would you like to share the POC or the branch for this
> > >work?
> >
> > The POC patch is attached. It currently supports the following
> > functionali
Hi Japin,
> You should use a different user that has different length from your current
> one.
> For example:
>
> px@localhost$ make check-world
This is fixed in the latest commit:
https://github.com/zli236/postgres/commits/ddl_replication
Thanks,
Zheng
On Thu, Mar 17, 2022 at 2:47 AM Zheng Li wrote:
>
> Hi,
>
> >If you don't mind, would you like to share the POC or the branch for this
> >work?
>
> The POC patch is attached. It currently supports the following
> functionalities:
Thanks for sharing, I will look into it.
> >In such cases why do
On Sat, 19 Mar 2022 at 01:25, Zheng Li wrote:
> Hello,
>
> Thanks for the quick review!
>
>> And, when I try to use git am to apply the patch, it complains:
>>
>> $ git am ~/0001-syntax-pg_publication-pg_dump-ddl_replication.patch
>> Patch format detection failed.
>
> git apply w
Hello,
Thanks for the quick review!
> And, when I try to use git am to apply the patch, it complains:
>
> $ git am ~/0001-syntax-pg_publication-pg_dump-ddl_replication.patch
> Patch format detection failed.
git apply works for me. I'm not sure why git am complains.
I also created
On Fri, 18 Mar 2022 at 08:18, Zheng Li wrote:
> Hello,
>
> Attached please find the broken down patch set. Also fixed the failing
> TAP tests Japin reported.
>
Here are some comments for the new patches:
Seems like you forget initializing the *ddl_level_given after entering the
parse_publicat
On Fri, 18 Mar 2022 at 08:22, Japin Li wrote:
> On Fri, 18 Mar 2022 at 00:22, Zheng Li wrote:
>> Hello Japin,
>>>The new patch change the behavior of publication, when we drop a table
>>>on publisher, the table also be dropped on subscriber, and this made the
>>>regression testa failed, since t
On Fri, 18 Mar 2022 at 08:18, Zheng Li wrote:
> Hello,
>
> Attached please find the broken down patch set. Also fixed the failing
> TAP tests Japin reported.
>
Thanks for updating the patchset, I will try it later.
--
Regrads,
Japin Li.
ChengDu WenWu Information Technology Co.,Ltd.
On Fri, 18 Mar 2022 at 00:22, Zheng Li wrote:
> Hello Japin,
>>The new patch change the behavior of publication, when we drop a table
>>on publisher, the table also be dropped on subscriber, and this made the
>>regression testa failed, since the regression test will try to drop the
>>table on su
Hello Alvaro,
> I think this is a pretty interesting and useful feature.
>
> Did you see some old code I wrote towards this goal?
> https://www.postgresql.org/message-id/20150215044814.gl3...@alvh.no-ip.org
> The intention was that DDL would produce some JSON blob that accurately
> describes the D
On Thu, 17 Mar 2022 at 05:17, Zheng Li wrote:
> Hi,
>
>>If you don't mind, would you like to share the POC or the branch for this
>>work?
>
> The POC patch is attached. It currently supports the following
> functionalities:
Hi,
When I try to run regression test, there has some errors.
make[
Hi, Zhang Li
On Thu, 17 Mar 2022 at 05:17, Zheng Li wrote:
> Hi,
>
>>If you don't mind, would you like to share the POC or the branch for this
>>work?
>
> The POC patch is attached. It currently supports the following
> functionalities:
> 1. Configure either database level or table level DDL
Hello
I think this is a pretty interesting and useful feature.
Did you see some old code I wrote towards this goal?
https://www.postgresql.org/message-id/20150215044814.gl3...@alvh.no-ip.org
The intention was that DDL would produce some JSON blob that accurately
describes the DDL that was run; th
+
On Sun, Mar 13, 2022 at 5:05 PM Dilip Kumar wrote:
>
> On Mon, Feb 21, 2022 at 9:43 PM Zheng Li wrote:
> >
> > Hello,
> >
> > One of the most frequently requested improvements from our customers
> > is to reduce downtime associated with software updates (both major and
> > minor versions). To
On Mon, Feb 21, 2022 at 9:43 PM Zheng Li wrote:
>
> Hello,
>
> One of the most frequently requested improvements from our customers
> is to reduce downtime associated with software updates (both major and
> minor versions). To do this, we have reviewed potential contributions to
> improving logica
201 - 300 of 304 matches
Mail list logo