pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Andrew Dunstan <andrew@dunslane.net>
To: pgsql-committers@lists.postgresql.org
Subject: pgsql: Avoid unfortunate IPC::Run path caching in PostgresNode
Date: Tue, 20 Apr 2021 14:36:34 +0000
Message-ID: <E1lYrUQ-0002WH-AL@gemulon.postgresql.org> (raw)

Avoid unfortunate IPC::Run path caching in PostgresNode

Commit b34ca595ab provided for installation-aware instances of
PostgresNode. However, it turns out that IPC::Run works against this by
caching the path to a binary and not consulting the path again, even if
it has changed. We work around this by calling Postgres binaries with
the installed path rather than just a bare name to be looked up in the
environment path, if there is an installed path. For the common case
where there is no installed path we continue to use the bare command
name.

Diagnosis and solution from Mark Dilger

Discussion: https://postgr.es/m/E8F512F8-B4D6-4514-BA8D-2E671439DA92@enterprisedb.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/95c3a1956ec9eac686c1b69b033dd79211b72343

Modified Files
--------------
src/test/perl/PostgresNode.pm | 36 +++++++++++++++++++++++++++++++-----
1 file changed, 31 insertions(+), 5 deletions(-)



Message-ID: <E1lYrUQ-0002WH-AL@gemulon.postgresql.org>
Permalink:  ../E1lYrUQ-0002WH-AL@gemulon.postgresql.org/
Also on:    postgresql.org/message-id/E1lYrUQ-0002WH-AL@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: andrew@dunslane.net
  Subject: Re: pgsql: Avoid unfortunate IPC::Run path caching in PostgresNode
  In-Reply-To: <E1lYrUQ-0002WH-AL@gemulon.postgresql.org>
  References: <E1lYrUQ-0002WH-AL@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