Re: tests against running server occasionally fail, postgres_fdw & tenk1

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Andres Freund <andres(at)anarazel(dot)de>
Cc: pgsql-hackers(at)postgresql(dot)org, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Fujii Masao <fujii(at)postgresql(dot)org>
Subject: Re: tests against running server occasionally fail, postgres_fdw & tenk1
Date: 2023-02-27 15:01:25
Message-ID: 349133.1677510085@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

I wrote:
> ... maybe we could do "select 1 from
> pg_stat_activity where application_name = computed-pattern", but that
> has the same problem that a cache flush might have terminated the
> remote session.

Hah - I thought of a solution. We can avoid this race condition if
we make the remote session itself inspect pg_stat_activity and
return its displayed application_name. Just need a foreign table
that maps onto pg_stat_activity. Of course, this'd add yet another
layer of baroque-ness to a test section that I already don't think
is worth the trouble. Should we go that way, or just rip it out?

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2023-02-27 15:30:42 Re: pg_stat_bgwriter.buffers_backend is pretty meaningless (and more?)
Previous Message gkokolatos 2023-02-27 14:56:08 Re: Add LZ4 compression in pg_dump