pgsql: Move MarkCurrentTransactionIdLoggedIfAny() out of the critical s

From: Amit Kapila <akapila(at)postgresql(dot)org>
To: pgsql-committers(at)lists(dot)postgresql(dot)org
Subject: pgsql: Move MarkCurrentTransactionIdLoggedIfAny() out of the critical s
Date: 2021-11-02 03:50:17
Message-ID: E1mhkoT-0004H5-Va@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Move MarkCurrentTransactionIdLoggedIfAny() out of the critical section.

We don't modify any shared state in this function which could cause
problems for any concurrent session. This will make it look similar to the
other updates for the same structure (TransactionState) which avoids
confusion for future readers of code.

Author: Dilip Kumar
Reviewed-by: Amit Kapila
Discussion: https://postgr.es/m/E1mSoYz-0007Fh-D9@gemulon.postgresql.org

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/335397456b7e3f9f619038cb322fbfc9dd649d4f

Modified Files
--------------
src/backend/access/transam/xlog.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Fujii Masao 2021-11-02 13:50:57 pgsql: pgbench: Improve error-handling in pgbench.
Previous Message Amit Kapila 2021-11-02 03:13:44 pgsql: Replace XLOG_INCLUDE_XID flag with a more localized flag.