Re: ALTER EXTENSION ... UPGRADE;

From: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>, PostgreSQL Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: ALTER EXTENSION ... UPGRADE;
Date: 2010-12-10 23:00:47
Message-ID: DF0922B2-9688-49DF-AF73-097817C96E37@kineticode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Dec 10, 2010, at 2:58 PM, Tom Lane wrote:

> Maybe I misread David's meaning, but I thought he was saying that
> there's no value in inventing all those control file entries in the
> first place. Just hard-wire in ALTER EXTENSION UPGRADE the convention
> that the name of an upgrade script to upgrade from prior version VVV is
> EXTNAME-upgrade.VVV.sql (or any variant spelling of that you care for).
> What is the point of letting/making extension authors invent their own
> naming schemes? That has no benefit that I can perceive, and the
> disadvantage that lack of uniformity will confuse users.

Yes, except that the version number in the file name should be the version it upgrades *to*, not *from*.

> As for the question of what characters should be expected in version
> numbers, +1 for digits and dots only. There's no good reason for
> something else. Even the Debian document you quote points out that
> hyphens in upstream version numbers give them problems, and Red Hat
> style packaging rules flat out disallow hyphens. (hyphen-something is
> for the packager to use, not the upstream software.)

I've mandated semantic versions for PGXN, mainly because it's simple and because it's close enough to the version numbers used in core.

http://semver.org/

If we're going to be comparing version strings in file names, we'll need *something* to use to compare what's higher than another number.

Best,

David

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2010-12-10 23:01:44 Re: create tablespace fails silently, or succeeds improperly
Previous Message David E. Wheeler 2010-12-10 22:58:29 Re: ALTER EXTENSION ... UPGRADE;