From: Michael Paquier <michael@paquier.xyz>
To: pgsql-committers@lists.postgresql.org
Subject: Re: pgsql: Fix pattern matching logic for logs in TAP tests of pgbench
Date: Fri, 25 Jun 2021 08:51:19 +0900
Message-ID: <YNUad2HvgW+6eXyo@paquier.xyz> (raw)
In-Reply-To: <E1lwXJD-0005Kn-Jy@gemulon.postgresql.org>
References: <E1lwXJD-0005Kn-Jy@gemulon.postgresql.org>
On Thu, Jun 24, 2021 at 09:54:51PM +0000, Michael Paquier wrote:
> Fix pattern matching logic for logs in TAP tests of pgbench
>
> The logic checking for the format of per-thread logs used grep() with
> directly "$re", which would cause the test to consider all the logs as
> a match without caring about their format at all. Using "/$re/" makes
> grep() perform a regex test, which is what we want here.
>
> While on it, improve some of the tests to be more picky with the
> patterns expected and add more comments to describe the tests.
>
> Issue discovered while digging into a separate patch.
fairywren does not like that:
https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=fairywren&dt=2021-06-24%2022%3A36%3A14
not ok 302 - transaction format for 001_pgbench_log_2
not ok 311 - transaction format for 001_pgbench_log_3
I am not sure if this is a pre-existing bug in pgbench itself
regarding the way we generate the logs or an issue with fairywren's
perl installation.
Andrew, what's the format of the per-thread logs generated on this
host when running the commands? I'd bet that the checks for the
client IDs are right, but that some parts of the regex are too picky
when it comes to this host.
--
Michael
Attachments:
signature.asc (application/pgp-signature, 832B) download
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: Fix pattern matching logic for logs in TAP tests of pgbench
In-Reply-To: <YNUad2HvgW+6eXyo@paquier.xyz>
References: <E1lwXJD-0005Kn-Jy@gemulon.postgresql.org> <YNUad2HvgW+6eXyo@paquier.xyz>
* 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