Re: logical streaming of xacts via test_decoding is broken

From: Dilip Kumar <dilipbalaut(at)gmail(dot)com>
To: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
Cc: Michael Paquier <michael(at)paquier(dot)xyz>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>
Subject: Re: logical streaming of xacts via test_decoding is broken
Date: 2020-11-11 13:34:59
Message-ID: CAFiTN-vvSxnN04W2WawTd=NfSxTsNiMf0unvP=Sb7xgWjPR2=g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Nov 11, 2020 at 6:59 PM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
>
> On Wed, Nov 11, 2020 at 10:00 AM Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
> >
> > On Tue, Nov 10, 2020 at 7:20 PM Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> wrote:
> > >
> > > On Tue, Nov 10, 2020 at 2:25 PM Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
> > > >
> > >
> > > You can probably add a comment as to why we are disallowing this case.
> > > I thought of considering 'stream-changes' parameter here because it
> > > won't make sense to give this parameter without it, however, it seems
> > > that is not necessary but maybe adding a comment
> > > here in that regard would be a good idea.
> >
> > Should we also consider the case that if the user just passed
> > skip_empty_streams to true then we should automatically set
> > skip_empty_xacts to true?
> >
>
> Is there any problem if we don't do this? Actually, adding
> dependencies on parameters is confusing so I want to avoid that unless
> it is really required.
>
> > And we will allow the 'skip_empty_streams' parameter only if
> > stream-changes' is true.

The reason behind this thought is that if the user doesn't pass any
value for 'skip_empty_xacts' then the default value will be false and
if the user only pass 'skip_empty_streams' to true then we will error
out assuming that skip_empty_xacts is false but skip_empty_streams is
true. So it seems instead of error out we can assume that
skip_empty_streams true mean skip_empty_xacts is also true if nothing
is passed for that.

> Can't we simply ignore 'skip_empty_streams' if 'stream-changes' is not given?

Yeah, we can do that.

--
Regards,
Dilip Kumar
EnterpriseDB: http://www.enterprisedb.com

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Konstantin Knizhnik 2020-11-11 13:36:02 Re: avoid bitmapOR-ing indexes with scan condition inconsistent with partition constraint
Previous Message Amit Kapila 2020-11-11 13:30:44 Re: logical streaming of xacts via test_decoding is broken