Re: postgres_fdw: commit remote (sub)transactions in parallel during pre-commit
Etsuro Fujita <etsuro.fujita@gmail.com>
From: Etsuro Fujita <etsuro.fujita@gmail.com>
To: Fujii Masao <masao.fujii@oss.nttdata.com>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2022-01-06T08:29:23Z
Lists: pgsql-hackers
Attachments
- v2-0001-postgres-fdw-Add-support-for-parallel-commit.patch (application/octet-stream) patch v2-0001
- v2-0002-postgres-fdw-Add-support-for-parallel-abort.patch (application/octet-stream) patch v2-0002
On Fri, Dec 3, 2021 at 6:07 PM Fujii Masao <masao.fujii@oss.nttdata.com> wrote: > On 2021/11/16 18:55, Etsuro Fujita wrote: > > I changed my mind; I’ll update the patch to ignore the error as > > before, because 1) as far as I know, there are no reports from the > > field concerning that we ignore all kinds of errors in cleaning up the > > prepared statements, so maybe we don’t need to change that, and 2) we > > already committed at least one of the remote transactions, so it’s not > > good to abort the local transaction unless we really have to. Done. > Are you planning to update the patch? In addition to this change, > at least documentation about new parallel_commit parameter needs > to be included in the patch. Done. Attached is a new version. * 0001 This is an updated version of the previous patch. In addition to the above, I expanded a comment in do_sql_command_end() a bit to explain why we do PQconsumeInput() before doing pgfdw_get_result(), to address your comment. Also, I moved the code to finish closing pending (sub)transactions in pgfdw_xact_callback()(pgfdw_subxact_callback()) into separate functions. Also, I modified regression test cases a bit to access multiple foreign servers. * 0002 This is a WIP patch for parallel abort. I added an option parallel_abort for this, because I thought it would be good to enable/disable these separately. I didn’t do any performance tests yet. Sorry for the long delay. Best regards, Etsuro Fujita
Commits
-
postgres_fdw: Add support for parallel abort.
- 983ec23007bd 16.0 landed
-
Refine the definition of page-level freezing.
- b37a08323964 16.0 cited
-
postgres_fdw: Update comments in make_new_connection().
- 4036bcbbb928 15.0 landed
-
postgres_fdw: Minor cleanup for pgfdw_abort_cleanup().
- 56566835039a 15.0 landed
-
postgres_fdw: Add support for parallel commit.
- 04e706d4238f 15.0 landed
-
Fix ruleutils.c's dumping of whole-row Vars in more contexts.
- 43c2175121c8 15.0 cited
-
postgres_fdw: Refactor transaction rollback code to avoid code duplication.
- 85c69611288f 15.0 cited