Re: modules

From: Martijn van Oosterhout <kleptog(at)svana(dot)org>
To: Aidan Van Dyk <aidan(at)highrise(dot)ca>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Gregory Stark <stark(at)enterprisedb(dot)com>, Jeremy Drake <pgsql(at)jdrake(dot)com>, Peter Eisentraut <peter_e(at)gmx(dot)net>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Greg Sabino Mullane <greg(at)turnstep(dot)com>
Subject: Re: modules
Date: 2008-04-05 11:41:20
Message-ID: 20080405114120.GA17265@svana.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general pgsql-hackers

On Fri, Apr 04, 2008 at 08:22:51PM -0400, Aidan Van Dyk wrote:
> Today was the first time I actually ever looked at the create function
> and create language code, and I'm actually suprised at how little
> "contract" there seems to be between a object file and the created
> function. But since it's always been guarded by super-user, it's
> obviously not been an issue...

There was once a discussion about allowing people to add declarations
to the C code indicating the types and returns type to avoid stupid
errors (you could just say CREATE FUNCTION foo FROM module.so and it
would get the types/volitility/etc from the module).

It even went so far that you could build the install/deinstall scripts
into the module itself, so all postgres had to do was dlopen() the
module it could access the install script. It fails due to the fact
that modules that don't require compilation are left out in the cold...

Have a nice day,
--
Martijn van Oosterhout <kleptog(at)svana(dot)org> http://svana.org/kleptog/
> Please line up in a tree and maintain the heap invariant while
> boarding. Thank you for flying nlogn airlines.

In response to

  • Re: modules at 2008-04-05 00:22:51 from Aidan Van Dyk

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Glyn Astill 2008-04-05 11:47:08 Re: [Slony1-general] ERROR: XX000: cache lookup failed for relation
Previous Message Pedro Doria Meunier 2008-04-05 11:25:20 Re: default value based on select

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Dunstan 2008-04-05 12:07:27 Re: modules
Previous Message Gregory Stark 2008-04-05 09:43:47 Re: modules