Re: Using LibPq in TAP tests via FFI - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Using LibPq in TAP tests via FFI
Date
Msg-id 20240614162530.lqupjceyixs433w4@awork3.anarazel.de
Whole thread Raw
In response to Re: Using LibPq in TAP tests via FFI  (Andrew Dunstan <andrew@dunslane.net>)
Responses Re: Using LibPq in TAP tests via FFI
List pgsql-hackers
Hi,

On 2024-06-14 11:11:38 -0400, Andrew Dunstan wrote:
> On 2024-06-14 Fr 11:09, Andrew Dunstan wrote:
> > Over at [1] Andres expressed enthusiasm for enabling TAP tests to call
> > LibPQ directly via FFI, and there was some support from others as well.
> > Attached is a very rough POC for just that.There are two perl modules,
> > one which wraps libpq (or almost all of it) in perl, and another which
> > uses that module to create a session object that can be used to run SQL.

What are your current thoughts about a fallback for this?  It seems possible
to implement the session module ontop of BackgroundPsql.pm, if necessary. But
I suspect we'll eventually get to a point where that gets less and less
convenient.


How much of a dependency is FFI::Platypus, compared to requiring perl headers
to be installed?  In case FFI::Platypus is a complicted dependency, a small XS
wrapper could be an alternative.

Greetings,

Andres Freund



pgsql-hackers by date:

Previous
From: "David E. Wheeler"
Date:
Subject: jsonpath: Missing regex_like && starts with Errors?
Next
From: Tom Lane
Date:
Subject: Re: libpq contention due to gss even when not using gss