pg.ddx.io  pgsql-committers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Alvaro Herrera <alvherre@alvh.no-ip.org>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: Pavel Stehule <pavel.stehule@gmail.com>
Cc: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers@lists.postgresql.org
Subject: Re: pgsql: Default to hidden visibility for extension libraries where possi
Date: Tue, 19 Jul 2022 16:28:07 +0200
Message-ID: <20220719142807.2zex4cczycc5nqq5@alvherre.pgsql> (raw)
In-Reply-To: <1057666.1658238352@sss.pgh.pa.us>

[ Redirecting thread to -hackers from -committers ]

On 2022-Jul-19, Tom Lane wrote:

> Alvaro Herrera <alvherre@alvh.no-ip.org> writes:

> > Do you just need to send a patch to add an exports.txt file to
> > src/pl/plpgsql/src/ for these functions?
> 
> The precedent of plpython says that PGDLLEXPORT markers are sufficient.
> But yeah, we need a list of exactly which functions need to be
> re-exposed.  I imagine pldebugger has its own needs.

A reasonable guess.  I went as far as downloading pldebugger and
compiling it, but it doesn't have a test suite of its own, so I couldn't
verify anything about it.  I did notice that plpgsql_check is calling
function load_external_function(), and that doesn't appear in
pldebugger.  I wonder if the find_rendezvous_variable business is at
play.

Anyway, the minimal patch that makes plpgsql_check tests pass is
attached.  This seems a bit random.  Maybe it'd be better to have a
plpgsql_internal.h with functions that are exported only for plpgsql
itself, and keep plpgsql.h with a set of functions, all marked
PGDLLEXPORT, that are for external use.


... oh, and:

$ postmaster -c shared_preload_libraries=plugin_debugger
2022-07-19 16:27:24.006 CEST [742142] FATAL:  cannot request additional shared memory outside shmem_request_hook

-- 
Álvaro Herrera        Breisgau, Deutschland  —  https://www.EnterpriseDB.com/

Attachments:

  0001-add-PGDLLEXPORTS-to-plpgsql.patch (text/x-diff, 0B) download

view thread (27+ messages)  latest in thread

Message-ID: <20220719142807.2zex4cczycc5nqq5@alvherre.pgsql>
Permalink:  ../20220719142807.2zex4cczycc5nqq5@alvherre.pgsql/
Also on:    postgresql.org/message-id/20220719142807.2zex4cczycc5nqq5@alvherre.pgsql

 ·  · 

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: alvherre@alvh.no-ip.org, tgl@sss.pgh.pa.us, pavel.stehule@gmail.com, andres@anarazel.de, pgsql-hackers@lists.postgresql.org
  Subject: Re: pgsql: Default to hidden visibility for extension libraries where possi
  In-Reply-To: <20220719142807.2zex4cczycc5nqq5@alvherre.pgsql>
  References: <1057666.1658238352@sss.pgh.pa.us> <20220719142807.2zex4cczycc5nqq5@alvherre.pgsql>

* 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