Re: Extensions, this time with a patch - Mailing list pgsql-hackers

From David E. Wheeler
Subject Re: Extensions, this time with a patch
Date
Msg-id A9631455-5CE3-444D-9A59-203F5BC26124@kineticode.com
Whole thread Raw
In response to Re: Extensions, this time with a patch  (Dimitri Fontaine <dimitri@2ndQuadrant.fr>)
Responses Re: Extensions, this time with a patch
Re: Extensions, this time with a patch
List pgsql-hackers
On Oct 20, 2010, at 3:12 PM, Dimitri Fontaine wrote:

> So, the idea is that $(EXTENSION) is a list of extensions you're
> providing from the Makefile (most often, a list of one extension, but
> contrib/spi is an exception here). Each extension in the list must have
> a corresponding $EXTENSION.control file.
>
> This control file contains at minimum a single line for the name of the
> extension, but it's better already with a comment for users. I've been
> filling them for our extensions, pasting from the documentation:

Might I suggest instead a META.json file like PGXN requires? Here's a simple example:

{  "name": "pair",  "abstract": "A key/value pair data type",  "version": "0.1.0",  "maintainer": "David E. Wheeler
<david@justatheory.com>", "license": "postgresql", 
}

They can have a lot more information, too. Her's the one I actually shipped with pair:
 http://github.com/theory/kv-pair/blob/master/META.json

The meta spec is here:
 http://github.com/theory/pgxn/wiki/PGXN-Meta-Spec

Anyway, the point is that it might be useful for us to sync on this format. I went with JSON for a few reasons:

* CPAN is switching to it (from YAML)
* It's extremely widespread
* It's useful for ac-hoc REST-style requests
* The format will likely be in 9.1.

Thoughts?

BTW, really excited that you're finally getting EXTENSION done, Dim. This is going to be *great* for PostgreSQL
developers.I'll have to work it into my talk at West. 
 https://www.postgresqlconference.org/content/building-and-distributing-postgresql-extensions-without-learning-c

Best,

David



pgsql-hackers by date:

Previous
From: Greg Stark
Date:
Subject: Re: default_statistics_target WAS: max_wal_senders must die
Next
From: Bruce Momjian
Date:
Subject: Re: Issues with Quorum Commit