Re: multi-platform, multi-locale regression tests

Lists: pgsql-hackers
From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: <peter_e(at)gmx(dot)net>,<david(at)kineticode(dot)com>
Cc: <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 13:31:06
Message-ID: 4CDA4A3A0200002500037508@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

> Peter Eisentraut wrote:
> On tis, 2010-11-09 at 14:00 -0800, David E. Wheeler wrote:
>
>> I've been talking to Nasby and Dunstan about adding a
>> Test::More/pgTAP-based test suite to the core. It wouldn't run
>> with the usual core suite used by developers, which would continue
>> to use pg_regress. But they could run it if they wanted (and had
>> the prerequisites), and the build farm animals would run them
>> regularly.
>
> I'd welcome something like that, but I'm not sure that that's the
> best overall solution to this particular problem in the short run.
> But it would be great to have anyway.

For the Serializable Snapshot Isolation (SSI) patch I needed a test
suite which would handle concurrent sessions which interleaved
statements in predictable ways. I was told pgTAP wasn't a good
choice for that and went with Markus Wanner's dtester package. The
SSI patch adds a "dcheck" build target which is not included in any
others to run the dtester tests.

I don't know if dtester meets the other needs people have, or whether
this is a complementary approach, but it seemed worth mentioning.

-Kevin


From: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: <peter_e(at)gmx(dot)net>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 16:33:13
Message-ID: 08972E49-16F3-4496-81F5-132A74C1637A@kineticode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Nov 10, 2010, at 5:31 AM, Kevin Grittner wrote:

> For the Serializable Snapshot Isolation (SSI) patch I needed a test
> suite which would handle concurrent sessions which interleaved
> statements in predictable ways. I was told pgTAP wasn't a good
> choice for that and went with Markus Wanner's dtester package. The
> SSI patch adds a "dcheck" build target which is not included in any
> others to run the dtester tests.

Right. pgTAP doesn't run tests, it's just a collection of assertion functions written in SQL and PL/pgSQL. It could have been used via a forking Perl script that would connect to the proper boxes, run the tests, collect the results, etc. But it clearly would have been a PITA, and the path of least resistance is often the best solution when hacking. Going with dcheck, which already did what you wanted, was clearly the right choice.

Hopefully we can have the build farm animals run the dcheck target once SSI is committed.

Best,

David


From: David Fetter <david(at)fetter(dot)org>
To: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
Cc: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 17:12:23
Message-ID: 20101110171223.GC21921@fetter.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Wed, Nov 10, 2010 at 08:33:13AM -0800, David Wheeler wrote:
> On Nov 10, 2010, at 5:31 AM, Kevin Grittner wrote:
>
> > For the Serializable Snapshot Isolation (SSI) patch I needed a
> > test suite which would handle concurrent sessions which
> > interleaved statements in predictable ways. I was told pgTAP
> > wasn't a good choice for that and went with Markus Wanner's
> > dtester package. The SSI patch adds a "dcheck" build target which
> > is not included in any others to run the dtester tests.
>
> Right. pgTAP doesn't run tests, it's just a collection of assertion
> functions written in SQL and PL/pgSQL. It could have been used via
> a forking Perl script that would connect to the proper boxes, run
> the tests, collect the results, etc. But it clearly would have been
> a PITA, and the path of least resistance is often the best solution
> when hacking. Going with dcheck, which already did what you wanted,
> was clearly the right choice.
>
> Hopefully we can have the build farm animals run the dcheck target
> once SSI is committed.

Does Perl have some kind of concurrency-controlled test framework?

Cheers,
David.
--
David Fetter <david(at)fetter(dot)org> http://fetter.org/
Phone: +1 415 235 3778 AIM: dfetter666 Yahoo!: dfetter
Skype: davidfetter XMPP: david(dot)fetter(at)gmail(dot)com
iCal: webcal://www.tripit.com/feed/ical/people/david74/tripit.ics

Remember to vote!
Consider donating to Postgres: http://www.postgresql.org/about/donate


From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: peter_e(at)gmx(dot)net, david(at)kineticode(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 17:48:22
Message-ID: 4CDADAE6.4020005@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/10/2010 08:31 AM, Kevin Grittner wrote:
> I don't know if dtester meets the other needs people have, or whether
> this is a complementary approach, but it seemed worth mentioning.

Where is this available? Is it self-contained? And what does it require?

cheers

andrew


From: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 17:51:00
Message-ID: A416EB54-3CCA-4E33-9CA6-9A3E084103CC@kineticode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Nov 10, 2010, at 9:48 AM, Andrew Dunstan wrote:

>> I don't know if dtester meets the other needs people have, or whether
>> this is a complementary approach, but it seemed worth mentioning.
>
>
> Where is this available? Is it self-contained? And what does it require?

Python.

http://www.bluegap.ch/projects/dtester/

Best,

David


From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Andrew Dunstan" <andrew(at)dunslane(dot)net>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>
Cc: "Markus Wanner" <markus(at)bluegap(dot)ch>,<peter_e(at)gmx(dot)net>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 18:28:37
Message-ID: 4CDA8FF50200002500037533@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

"David E. Wheeler" <david(at)kineticode(dot)com> wrote:
> On Nov 10, 2010, at 9:48 AM, Andrew Dunstan wrote:

>> Where is this available? Is it self-contained? And what does it
>> require?
>
> Python.

And some optional python packages, like twisted.

> http://www.bluegap.ch/projects/dtester/

It looks like I may have raised the issue at a particularly
inopportune time -- it looks like maybe Markus is reloading his git
repo based on the new "official" git repo for PostgreSQL.

-Kevin


From: Marti Raudsepp <marti(at)juffo(dot)org>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: peter_e(at)gmx(dot)net, david(at)kineticode(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 19:09:23
Message-ID: AANLkTikFFijSYbnUym0=v6GDV2JyW32i=ZiE_XRPkVEL@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Wed, Nov 10, 2010 at 15:31, Kevin Grittner
<Kevin(dot)Grittner(at)wicourts(dot)gov> wrote:
> For the Serializable Snapshot Isolation (SSI) patch I needed a test
> suite which would handle concurrent sessions which interleaved
> statements in predictable ways.  I was told pgTAP wasn't a good
> choice for that and went with Markus Wanner's dtester package.

Sounds like you could use pgTAP with dblink to do the same? :)

Regards,
Marti


From: Markus Wanner <markus(at)bluegap(dot)ch>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 19:40:08
Message-ID: 4CDAF518.3080509@bluegap.ch
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Hi,

On 11/10/2010 07:28 PM, Kevin Grittner wrote:
> It looks like I may have raised the issue at a particularly
> inopportune time -- it looks like maybe Markus is reloading his git
> repo based on the new "official" git repo for PostgreSQL.

Thanks for noticing me. The dtester repository should be there again.
Sorry for the inconvenience.

Regards

Markus


From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: david(at)kineticode(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 21:58:20
Message-ID: 1289426300.13614.4.camel@vanquo.pezone.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On ons, 2010-11-10 at 07:31 -0600, Kevin Grittner wrote:
> I don't know if dtester meets the other needs people have, or whether
> this is a complementary approach, but it seemed worth mentioning.

The right tool for the right job, I'd say.

One thing to aim for, perhaps, would be to make all tools in use produce
a common output format, at least optionally, so that creating a common
test run dashboard or something like that is more easily possible. TAP
and xUnit come to mind.


From: "Kevin Grittner" <Kevin(dot)Grittner(at)wicourts(dot)gov>
To: "Marti Raudsepp" <marti(at)juffo(dot)org>
Cc: <peter_e(at)gmx(dot)net>,<david(at)kineticode(dot)com>, <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 22:06:10
Message-ID: 4CDAC2F20200002500037550@gw.wicourts.gov
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Marti Raudsepp <marti(at)juffo(dot)org> wrote:

> Sounds like you could use pgTAP with dblink to do the same? :)

I had never read through the docs for dblink until you posted this.
In fact, it appears that some testing of proper SSI behavior can be
added to standard regression tests with dblink (without needing
pgTAP) if there is some way to allow a contrib module like that to
be used. Would I have to add the SSI tests to the dblink regression
tests, or is there some more graceful way that might be made to
work?

I don't think this would be a sane way to *replace* the dcheck
tests, but it might be a way to work *some* testing of SSI into a
more frequently run test set.

-Kevin


From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>
Cc: Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, david(at)kineticode(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 22:15:16
Message-ID: 4CDB1974.5030407@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/10/2010 05:06 PM, Kevin Grittner wrote:
> Marti Raudsepp<marti(at)juffo(dot)org> wrote:
>
>> Sounds like you could use pgTAP with dblink to do the same? :)
>
> I had never read through the docs for dblink until you posted this.
> In fact, it appears that some testing of proper SSI behavior can be
> added to standard regression tests with dblink (without needing
> pgTAP) if there is some way to allow a contrib module like that to
> be used. Would I have to add the SSI tests to the dblink regression
> tests, or is there some more graceful way that might be made to
> work?
>
> I don't think this would be a sane way to *replace* the dcheck
> tests, but it might be a way to work *some* testing of SSI into a
> more frequently run test set.

We already use some contrib stuff in the regression tests. (It really is
time we stopped calling it contrib.)

cheers

andrew


From: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 22:39:04
Message-ID: FB222F05-6950-4C2E-A465-665511ACB5D4@kineticode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Nov 10, 2010, at 2:15 PM, Andrew Dunstan wrote:

> We already use some contrib stuff in the regression tests. (It really is time we stopped calling it contrib.)

Call them "core extensions". Works well considering Dimitri's work, which explicitly makes them extensions. So maybe change the directory name to "extensions" or "ext"?

Best,

David


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 23:17:52
Message-ID: 12741.1289431072@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

"David E. Wheeler" <david(at)kineticode(dot)com> writes:
> On Nov 10, 2010, at 2:15 PM, Andrew Dunstan wrote:
>> We already use some contrib stuff in the regression tests. (It really is time we stopped calling it contrib.)

> Call them "core extensions". Works well considering Dimitri's work, which explicitly makes them extensions. So maybe change the directory name to "extensions" or "ext"?

We've been calling it "contrib" for a dozen years, so that name is
pretty well baked in by now. IMO renaming it is pointless and will
accomplish little beyond creating confusion and making back-patches
harder. (And no, don't you dare breathe a word about git making that
all automagically better. I have enough back-patching experience with
git by now to be unimpressed; in fact, I notice that its rename-tracking
feature falls over entirely when trying to back-patch further than 8.3.
Apparently there's some hardwired limit on the number of files it can
cope with.)

regards, tom lane


From: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-10 23:39:55
Message-ID: FDBA0242-BC54-4025-BFFF-905A9995BBEC@kineticode.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Nov 10, 2010, at 3:17 PM, Tom Lane wrote:

> We've been calling it "contrib" for a dozen years, so that name is
> pretty well baked in by now. IMO renaming it is pointless and will
> accomplish little beyond creating confusion and making back-patches
> harder.

*Shrug*. Just change the name in the docs, then. It's currently "Additional Supplied Modules". Maybe just change that to "Additional Supplied Extensions" or, even better, "Core Extensions"?

Best,

David

> (And no, don't you dare breathe a word about git making that
> all automagically better. I have enough back-patching experience with
> git by now to be unimpressed; in fact, I notice that its rename-tracking
> feature falls over entirely when trying to back-patch further than 8.3.
> Apparently there's some hardwired limit on the number of files it can
> cope with.)

How often do you have to back-patch contrib, anyway?

David


From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 00:01:46
Message-ID: 4CDB326A.5060604@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/10/2010 06:17 PM, Tom Lane wrote:
> "David E. Wheeler"<david(at)kineticode(dot)com> writes:
>> On Nov 10, 2010, at 2:15 PM, Andrew Dunstan wrote:
>>> We already use some contrib stuff in the regression tests. (It really is time we stopped calling it contrib.)
>> Call them "core extensions". Works well considering Dimitri's work, which explicitly makes them extensions. So maybe change the directory name to "extensions" or "ext"?
> We've been calling it "contrib" for a dozen years, so that name is
> pretty well baked in by now. IMO renaming it is pointless and will
> accomplish little beyond creating confusion and making back-patches
> harder.

The current name causes constant confusion. It's a significant misnomer,
and leads people to distrust the code. There might be reasons not to
change, but you should at least recognize why the suggestion is being made.

> (And no, don't you dare breathe a word about git making that
> all automagically better. I have enough back-patching experience with
> git by now to be unimpressed; in fact, I notice that its rename-tracking
> feature falls over entirely when trying to back-patch further than 8.3.
> Apparently there's some hardwired limit on the number of files it can
> cope with.)

That's very sad. Did you file a bug?

cheers

andrew


From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-11 00:47:06
Message-ID: AANLkTiktTqUGDnpZJiSG6zoncgmjcKfHpdy_OdF7zkLP@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Wed, Nov 10, 2010 at 6:39 PM, David E. Wheeler <david(at)kineticode(dot)com> wrote:
> On Nov 10, 2010, at 3:17 PM, Tom Lane wrote:
>> We've been calling it "contrib" for a dozen years, so that name is
>> pretty well baked in by now.  IMO renaming it is pointless and will
>> accomplish little beyond creating confusion and making back-patches
>> harder.
>
> *Shrug*. Just change the name in the docs, then. It's currently "Additional Supplied Modules". Maybe just change that to "Additional Supplied Extensions" or, even better, "Core Extensions"?

I don't see any value to that change at all. Additional Supplied
Modules is a fine name. If there's a problem here, it's with the name
"contrib", but I don't see that there's enough value in changing that
to be worth the hassle. I think the big hurdle with contrib isn't
that it's called "contrib" but that it's not part of the core server
and, in many cases, enabling a contrib module means editing
postgresql.conf and bouncing the server. Of course, there are
certainly SOME people who wouldn't mind editing postgresql.conf and
bouncing the server but are scared off by the name contrib, but I
suspect the hassle-factor is the larger issue by a substantial margin.

>> (And no, don't you dare breathe a word about git making that
>> all automagically better.  I have enough back-patching experience with
>> git by now to be unimpressed; in fact, I notice that its rename-tracking
>> feature falls over entirely when trying to back-patch further than 8.3.
>> Apparently there's some hardwired limit on the number of files it can
>> cope with.)
>
> How often do you have to back-patch contrib, anyway?

[rhaas pgsql]$ git log --format=oneline `git merge-base REL9_0_STABLE
master`..REL9_0_STABLE | wc -l
247
[rhaas pgsql]$ git log --format=oneline `git merge-base REL9_0_STABLE
master`..REL9_0_STABLE contrib | wc -l
20

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 00:51:06
Message-ID: AANLkTin8LFWVmL=KLsORWYUvjFO4abjy1++QX2rNXgZ1@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Wed, Nov 10, 2010 at 7:01 PM, Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:
> The current name causes constant confusion. It's a significant misnomer, and
> leads people to distrust the code. There might be reasons not to change, but
> you should at least recognize why the suggestion is being made.

Is it your position that contrib code is as well-vetted as core code?

>>  (And no, don't you dare breathe a word about git making that
>> all automagically better.  I have enough back-patching experience with
>> git by now to be unimpressed; in fact, I notice that its rename-tracking
>> feature falls over entirely when trying to back-patch further than 8.3.
>> Apparently there's some hardwired limit on the number of files it can
>> cope with.)
>
> That's very sad. Did you file a bug?

It's intentional behavior. It gives up when there are too many
differences to avoid being slow.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 01:05:39
Message-ID: 4CDB4163.3000905@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/10/2010 07:51 PM, Robert Haas wrote:
> On Wed, Nov 10, 2010 at 7:01 PM, Andrew Dunstan<andrew(at)dunslane(dot)net> wrote:
>> The current name causes constant confusion. It's a significant misnomer, and
>> leads people to distrust the code. There might be reasons not to change, but
>> you should at least recognize why the suggestion is being made.
> Is it your position that contrib code is as well-vetted as core code?
>
>

A damn sight more than it used to be. I claim a bit of credit for that -
before the buildfarm existed it was quite poorly tested, but we can't
get away with that any more. (Ditto PLs and ECPG once we added those
into the buildfarm mix.) Of course, there are odd corners in the code.
But hstore, for example, has just had a major makeover, and pgcrypto is
pretty well maintained. Some other modules are less well loved. There
are a few small bits of the core code that have cobwebs too.

cheers

andrew


From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 01:27:43
Message-ID: AANLkTimtABfeDR+W-LYAwFjH3mf=4SBGs4Z3Fk_WKFyY@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Wed, Nov 10, 2010 at 8:05 PM, Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:
> On 11/10/2010 07:51 PM, Robert Haas wrote:
>> On Wed, Nov 10, 2010 at 7:01 PM, Andrew Dunstan<andrew(at)dunslane(dot)net>
>>  wrote:
>>>
>>> The current name causes constant confusion. It's a significant misnomer,
>>> and
>>> leads people to distrust the code. There might be reasons not to change,
>>> but
>>> you should at least recognize why the suggestion is being made.
>>
>> Is it your position that contrib code is as well-vetted as core code?
>
> A damn sight more than it used to be. I claim a bit of credit for that -
> before the buildfarm existed it was quite poorly tested, but we can't get
> away with that any more. (Ditto PLs and ECPG once we added those into the
> buildfarm mix.) Of course, there are odd corners in the code. But hstore,
> for example, has just had a major makeover, and pgcrypto is pretty well
> maintained. Some other modules are less well loved. There are a few small
> bits of the core code that have cobwebs too.

Fair enough. I think overall our code quality is good, and, over
time, it's probably risen both within and outside core. Still, I
think renaming contrib would likely be a lot more hassle than it's
worth, and I don't think it would do much to remove the central issue,
which is that installing extensions is a pain in the neck. Dimitri's
work will help with that somewhat, but there's still that nasty
business of needing to update shared_preload_libraries and bounce the
server, at least for some modules.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


From: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-11 13:07:58
Message-ID: m28w10ypn5.fsf@2ndQuadrant.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> I think the big hurdle with contrib isn't
> that it's called "contrib" but that it's not part of the core server
> and, in many cases, enabling a contrib module means editing
> postgresql.conf and bouncing the server. Of course, there are
> certainly SOME people who wouldn't mind editing postgresql.conf and
> bouncing the server but are scared off by the name contrib, but I
> suspect the hassle-factor is the larger issue by a substantial margin.

You're forgetting about the dump and restore problems you now have as
soon as you're using any contrib. They are more visible at upgrade time,
of course, but still bad enough otherwise.

Regards,
--
Dimitri Fontaine
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support


From: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib.
Date: 2010-11-11 13:21:26
Message-ID: m2vd44xag9.fsf@2ndQuadrant.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> work will help with that somewhat, but there's still that nasty
> business of needing to update shared_preload_libraries and bounce the
> server, at least for some modules.

We have 45 contribs (ls -l contrib | grep -c ^d), out of which:

auto_explain is shared_preload_libraries but I think could be
local_preload_libraries

pg_stat_statements is shared_preload_libraries (needs SHM)

and that's it

So my reading is that currently the only contrib module that needs more
than a server reload is pg_stat_statements, because it needs some shared
memory. Am I missing anything?

Ok, now I'll add the custom_variable_classes setting to the control
files in the extension's patch for the contribs that expose some of
them.

Regards,
--
Dimitri Fontaine
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support


From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 13:28:53
Message-ID: 4CDBEF95.4090803@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/10/2010 07:51 PM, Robert Haas wrote:
> (And no, don't you dare breathe a word about git making that
> all automagically better. I have enough back-patching experience with
> git by now to be unimpressed; in fact, I notice that its rename-tracking
> feature falls over entirely when trying to back-patch further than 8.3.
> Apparently there's some hardwired limit on the number of files it can
> cope with.)
>> That's very sad. Did you file a bug?
> It's intentional behavior. It gives up when there are too many
> differences to avoid being slow.

We should adopt that philosophy. I suggest we limit all tables in future
to 1m rows in the interests of speed.

cheers

andrew


From: Aidan Van Dyk <aidan(at)highrise(dot)ca>
To: Andrew Dunstan <andrew(at)dunslane(dot)net>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 15:17:15
Message-ID: AANLkTim4mDVX60Rt-JM0zgYSRA95EWHt=aZPc3yJO3uU@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Thu, Nov 11, 2010 at 8:28 AM, Andrew Dunstan <andrew(at)dunslane(dot)net> wrote:

>> It's intentional behavior.  It gives up when there are too many
>> differences to avoid being slow.

And, it's configurable, at least to diff and merge. If it's not
available in all the other porcelains, yes, that would be bugs that
should be fixed:
-l<num>
The -M and -C options require O(n^2) processing time where
n is the number of potential
rename/copy targets. This option prevents rename/copy
detection from running if the number
of rename/copy targets exceeds the specified number.

And can even be specified as config options diff.renameLimit and
merge.renameLimit.

> We should adopt that philosophy. I suggest we limit all tables in future to
> 1m rows in the interests of speed.

As long as it's configurable, and if it would make operations on
smaller tables faster, than go for it.

And we should by defualt limit shared_buffers to 32MB. Oh wait.

There are always tradeoffs when picking defaults, a-la-postgresql.conf.

We as a community are generally pretty quick to pick up the "defaults
are very conservative, make sure you tune ..." song when people
complain about "pg being too slow"

;-)

a.

--
Aidan Van Dyk                                             Create like a god,
aidan(at)highrise(dot)ca                                       command like a king,
http://www.highrise.ca/                                   work like a slave.


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Aidan Van Dyk <aidan(at)highrise(dot)ca>
Cc: Andrew Dunstan <andrew(at)dunslane(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 15:24:15
Message-ID: 14723.1289489055@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Aidan Van Dyk <aidan(at)highrise(dot)ca> writes:
>>> It's intentional behavior. It gives up when there are too many
>>> differences to avoid being slow.

> And, it's configurable, at least to diff and merge. If it's not
> available in all the other porcelains, yes, that would be bugs that
> should be fixed:

FWIW, I was seeing this with git cherry-pick, whose man page gives no
hint of supporting any such option.

> -l<num>
> The -M and -C options require O(n^2) processing time where
> n is the number of potential
> rename/copy targets. This option prevents rename/copy
> detection from running if the number
> of rename/copy targets exceeds the specified number.

Given that we have, in fact, never renamed any files in the history of
the project, I'm wondering exactly why it thinks that the number of
potential rename/copy targets isn't zero. The whole thing smells
broken to me, which is why I am unhappy about the idea of suddenly
starting to depend on it in a big way.

regards, tom lane


From: Marti Raudsepp <marti(at)juffo(dot)org>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Aidan Van Dyk <aidan(at)highrise(dot)ca>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 15:28:11
Message-ID: AANLkTikQnS_Zjr0N8Me2QM7uA_uMUEhJ0YaC5vPUMc4X@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Thu, Nov 11, 2010 at 17:24, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Given that we have, in fact, never renamed any files in the history of
> the project, I'm wondering exactly why it thinks that the number of
> potential rename/copy targets isn't zero.  The whole thing smells
> broken to me, which is why I am unhappy about the idea of suddenly
> starting to depend on it in a big way.

Because git doesn't do "rename tracking" at all -- a rename operation
is no different from a delete+add operation. Instead it tracks how
lines of code move around in the tree:
https://git.wiki.kernel.org/index.php/GitFaq#Why_does_git_not_.22track.22_renames.3F

Regards,
Marti


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Aidan Van Dyk <aidan(at)highrise(dot)ca>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 15:58:59
Message-ID: 15523.1289491139@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Aidan Van Dyk <aidan(at)highrise(dot)ca> writes:
> Can you share what commit you were trying to cherry-pick, and what
> your resulting commit was? I can try and take a quick look at them
> and see if there is something obviously fishy with how git's trying to
> merge the new commit on the old tree...

See yesterday's line_construct_pm() patches. I committed in HEAD and
then did "git cherry-pick master" in each back branch. These all worked,
which would be the minimum expectation for a single-file patch against
a function that hasn't changed since 1999. But in the older branches
it bleated about shutting off rename detection because of too many files
(sorry, don't have the exact message in front of me, but that was the
gist of it). Not the sort of thing that gives one a warm feeling about
the tool. I've seen this before when trying to use git cherry-pick,
but I forget on which other patches exactly.

Oh, for the record:
$ git --version
git version 1.7.3

regards, tom lane


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Marti Raudsepp <marti(at)juffo(dot)org>
Cc: Aidan Van Dyk <aidan(at)highrise(dot)ca>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 16:08:01
Message-ID: 15712.1289491681@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Marti Raudsepp <marti(at)juffo(dot)org> writes:
> On Thu, Nov 11, 2010 at 17:24, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>> Given that we have, in fact, never renamed any files in the history of
>> the project, I'm wondering exactly why it thinks that the number of
>> potential rename/copy targets isn't zero.

> Because git doesn't do "rename tracking" at all -- a rename operation
> is no different from a delete+add operation. Instead it tracks how
> lines of code move around in the tree:
> https://git.wiki.kernel.org/index.php/GitFaq#Why_does_git_not_.22track.22_renames.3F

Hmmm ... so rename tracking is O(N^2) in the total number of patches
applied, or lines patched, or some such measure, between the branches
you're trying to patch between? Ugh. Doesn't sound like something
we want to grow dependent on.

regards, tom lane


From: Andrew Dunstan <andrew(at)dunslane(dot)net>
To: Aidan Van Dyk <aidan(at)highrise(dot)ca>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Marti Raudsepp <marti(at)juffo(dot)org>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 16:13:17
Message-ID: 4CDC161D.7010303@dunslane.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/11/2010 10:17 AM, Aidan Van Dyk wrote:
>
>> We should adopt that philosophy. I suggest we limit all tables in future to
>> 1m rows in the interests of speed.
> As long as it's configurable, and if it would make operations on
> smaller tables faster, than go for it.
>
> And we should by defualt limit shared_buffers to 32MB. Oh wait.
>
> There are always tradeoffs when picking defaults, a-la-postgresql.conf.
>
> We as a community are generally pretty quick to pick up the "defaults
> are very conservative, make sure you tune ..." song when people
> complain about "pg being too slow"
>
> ;-)
>

Well, I was of course being facetious. But since you mention it,
Postgres is conservative about its defaults because it's a server. I
don't think quite the same considerations apply to developer software
that will be running on a workstation. And Tom's complaint was about
what he saw as incorrect behavior. Our defaults might hurt performance,
but I don't think they trade speed for incorrect behavior.

Anyway, revenons à nos moutons.

cheers

andrew


From: Marko Kreen <markokr(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Marti Raudsepp <marti(at)juffo(dot)org>, Aidan Van Dyk <aidan(at)highrise(dot)ca>, Andrew Dunstan <andrew(at)dunslane(dot)net>, Robert Haas <robertmhaas(at)gmail(dot)com>, "David E(dot) Wheeler" <david(at)kineticode(dot)com>, Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, peter_e(at)gmx(dot)net, pgsql-hackers(at)postgresql(dot)org
Subject: Re: renaming contrib. (was multi-platform, multi-locale regression tests)
Date: 2010-11-11 20:15:54
Message-ID: AANLkTi=Duxx06tUnrmh2VOwnnOOOmAdMt_mMZtzyFVne@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Thu, Nov 11, 2010 at 6:08 PM, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
> Marti Raudsepp <marti(at)juffo(dot)org> writes:
>> On Thu, Nov 11, 2010 at 17:24, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> wrote:
>>> Given that we have, in fact, never renamed any files in the history of
>>> the project, I'm wondering exactly why it thinks that the number of
>>> potential rename/copy targets isn't zero.
>
>> Because git doesn't do "rename tracking" at all -- a rename operation
>> is no different from a delete+add operation. Instead it tracks how
>> lines of code move around in the tree:
>> https://git.wiki.kernel.org/index.php/GitFaq#Why_does_git_not_.22track.22_renames.3F
>
> Hmmm ... so rename tracking is O(N^2) in the total number of patches
> applied, or lines patched, or some such measure, between the branches
> you're trying to patch between?  Ugh.  Doesn't sound like something
> we want to grow dependent on.

No, it's dependant on files changed between two trees.

It does not analyze history when doing rename tracking.

Default limit is 200. It should be easy to calculate whats needed for Postgres.

--
marko


From: Markus Wanner <markus(at)bluegap(dot)ch>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Kevin Grittner <Kevin(dot)Grittner(at)wicourts(dot)gov>, david(at)kineticode(dot)com, pgsql-hackers(at)postgresql(dot)org
Subject: Re: multi-platform, multi-locale regression tests
Date: 2010-11-12 09:08:47
Message-ID: 4CDD041F.3090702@bluegap.ch
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On 11/10/2010 10:58 PM, Peter Eisentraut wrote:
> One thing to aim for, perhaps, would be to make all tools in use produce
> a common output format, at least optionally, so that creating a common
> test run dashboard or something like that is more easily possible. TAP
> and xUnit come to mind.

Note that dtester features a TAP reporter. However, the way Kevin uses
dtester, that probably won't give useful results. (As he uses custom
print statements to do more detailed reporting than TAP could ever give
you).

Regards

Markus Wanner