From: Álvaro Herrera <alvherre@alvh.no-ip.org>
To: Kyotaro Horiguchi <horikyota.ntt@gmail.com>
Cc: daniele.varrazzo@gmail.com, "pgsql-hackers@lists.postgresql.org" <pgsql-hackers@lists.postgresql.org>
Subject: Re: Using PQexecQuery in pipeline mode produces unexpected Close messages
Date: Mon, 13 Jun 2022 13:09:48 +0200
Message-ID: <cbddf6bf-aa06-47fa-ab1d-d73a58d4e89f@www.fastmail.com> (raw)
In-Reply-To: <20220610.152544.1597540405935332165.horikyota.ntt@gmail.com>
References: <CA+mi_8bvD0_CW3sumgwPvWdNzXY32itoG_16tDYRu_1S2gV2iw@mail.gmail.com>
<202206081508.pwq4ne3df2si@alvherre.pgsql>
<20220610.152544.1597540405935332165.horikyota.ntt@gmail.com>
On Fri, Jun 10, 2022, at 8:25 AM, Kyotaro Horiguchi wrote:
>
> The current implement of PQsendQueryInternal looks like the result of
> a misunderstanding of the doc. In the regression tests, that path is
> excercised only for an error case, where no CloseComplete comes.
>
> The attached adds a test for the normal-path of pipelined
> PQsendQuery() to simple_pipeline test then modifies that function not
> to send Close message. Without the fix, the test fails by "unexpected
> notice" even if the trace matches the "expected" content.
Hah, the patch I wrote is almost identical to yours, down to the notice processor counting the number of notices received. The only difference is that I put my test in pipeline_abort.
Sadly, it looks like I won't be able to get this patched pushed for 14.4.
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 using the --to and --cc options:
reply via email
To: pgsql-bugs@postgresql.org
Cc: alvherre@alvh.no-ip.org, horikyota.ntt@gmail.com, pgsql-hackers@lists.postgresql.org
Subject: Re: Using PQexecQuery in pipeline mode produces unexpected Close messages
In-Reply-To: <cbddf6bf-aa06-47fa-ab1d-d73a58d4e89f@www.fastmail.com>
* 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