pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Add some assertions in syncrep.c
Date: Fri, 01 Nov 2019 14:00:16 +0000
Message-ID: <E1iQXTM-0008Ov-Ni@gemulon.postgresql.org> (raw)

Add some assertions in syncrep.c

A couple of routines assume that the LWLock SyncRepLock needs to be
taken, so add a couple of assertions to be sure of that.  Also, when
waiting for a given LSN at transaction commit, the code implied that the
syncrep queue cleanup happens while holding interrupts, but the code
never checked after that.

Author: Michael Paquier
Reviewed-by: Fujii Masao, Kyotaro Horiguchi, Dongming Liu
Discussion: https://postgr.es/m/a0806273-8bbb-43b3-bbe1-c45a58f6ae21.lingce.ldm@alibaba-inc.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/e174f699c476a4cc01875211a5f43e57c3190a37

Modified Files
--------------
src/backend/replication/syncrep.c | 16 +++++++++++++++-
1 file changed, 15 insertions(+), 1 deletion(-)



Message-ID: <E1iQXTM-0008Ov-Ni@gemulon.postgresql.org>
Permalink:  ../E1iQXTM-0008Ov-Ni@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1iQXTM-0008Ov-Ni@gemulon.postgresql.org

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-committers@postgresql.org
  Cc: michael@paquier.xyz
  Subject: Re: pgsql: Add some assertions in syncrep.c
  In-Reply-To: <E1iQXTM-0008Ov-Ni@gemulon.postgresql.org>
  References: <E1iQXTM-0008Ov-Ni@gemulon.postgresql.org>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox