Re: PATCH: logical_work_mem and logical streaming of large in-progress transactions

From: Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>
To: Dilip Kumar <dilipbalaut(at)gmail(dot)com>
Cc: Erik Rijkers <er(at)xs4all(dot)nl>, Kuntal Ghosh <kuntalghosh(dot)2007(at)gmail(dot)com>, Tomas Vondra <tomas(dot)vondra(at)2ndquadrant(dot)com>, Michael Paquier <michael(at)paquier(dot)xyz>, Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: PATCH: logical_work_mem and logical streaming of large in-progress transactions
Date: 2020-06-22 10:56:44
Message-ID: CAA4eK1KPErF2tJwp0WYjpcvSmgLHqSJKF89soN9FhcNHdVfqBQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Jun 18, 2020 at 9:02 PM Dilip Kumar <dilipbalaut(at)gmail(dot)com> wrote:
>
> Yes, I have made the changes. Basically, now I am only using the
> XLOG_XACT_INVALIDATIONS for generating all the invalidation messages.
> So whenever we are getting the new set of XLOG_XACT_INVALIDATIONS, we
> are directly appending it to the txn->invalidations. I have tested
> the XLOG_INVALIDATIONS part but while sending this mail I realized
> that we could write some automated test for the same.
>

Can you share how you have tested it?

> I will work on
> that soon.
>

Cool, I think having a regression test for this will be a good idea.

@@ -2012,8 +2014,6 @@ ReorderBufferForget(ReorderBuffer *rb,
TransactionId xid, XLogRecPtr lsn)
if (txn->base_snapshot != NULL && txn->ninvalidations > 0)
ReorderBufferImmediateInvalidation(rb, txn->ninvalidations,
txn->invalidations);
- else
- Assert(txn->ninvalidations == 0);

Why this Assert is removed?

Apart from above, I have made a number of changes in
0002-WAL-Log-invalidations-at-command-end-with-wal_le to remove some
unnecessary changes, edited comments, ran pgindent and updated the
commit message. If you are fine with these changes, then do include
them in your next version.

--
With Regards,
Amit Kapila.
EnterpriseDB: http://www.enterprisedb.com

Attachment Content-Type Size
v28-0001-Immediately-WAL-log-subtransaction-and-top-level.amit.patch application/octet-stream 11.1 KB
v28-0002-WAL-Log-invalidations-at-command-end-with-wal_le.amit.patch application/octet-stream 15.5 KB

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Josef Šimánek 2020-06-22 10:57:53 Re: [PATCH] Initial progress reporting for COPY command
Previous Message Josef Šimánek 2020-06-22 08:21:13 Re: [PATCH] Initial progress reporting for COPY command