FinishPreparedTransaction missing HOLD_INTERRUPTS section

From: Stas Kelvich <s(dot)kelvich(at)postgrespro(dot)ru>
To: PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: FinishPreparedTransaction missing HOLD_INTERRUPTS section
Date: 2018-04-27 21:36:16
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers


It seems that during COMMIT PREPARED FinishPreparedTransaction() doesn't
hold interrupts around writing to wal and cleaning up ProcArray and GXact
entries. At least RemoveTwoPhaseFile (which is called in between) can print
a warning with ereport(), which, in turn will check for interrupts and
therefore can cancel backend or throw an error before GXact clean-up.

Other similar places like CommitTransaction and PrepareTransaction have
such hold interrupts sections.

Stas Kelvich
Postgres Professional:
The Russian Postgres Company

Attachment Content-Type Size
0001-Add-HOLD_INTERRUPTS-section-into-FinishPreparedTrans.patch application/octet-stream 1.3 KB


Browse pgsql-hackers by date

  From Date Subject
Next Message Andres Freund 2018-04-27 22:28:42 Postgres, fsync, and OSs (specifically linux)
Previous Message Tom Lane 2018-04-27 21:15:50 Re: Goodbye pg_pltemplate, hello trusted extensions