Re: parallel regression test output

Lists: pgsql-hackers
From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: pgsql-hackers(at)postgresql(dot)org
Subject: parallel regression test output
Date: 2010-01-17 20:19:08
Message-ID: 1263759548.11833.43.camel@vanquo.pezone.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

There is something slightly funny about the regression test output.
When it starts a parallel group, it prints something like

parallel group (14 tests): select_views portals_p2 rules foreign_key
cluster dependency guc bitmapops combocid tsearch tsdicts foreign_data
window xmlmap

One would think that it prints this as the tests are started, but it
actually prints it as the tests finish. The last one or two test names
are always printed after a considerable delay, probably because of
terminal timing issues, which I have found confusing on several
occasions.

Note also that that behavior is inconsistent with that of a serial test
like

test misc ... ok

Here, the first part of the line is printed before that test starts, and
the result is printed after.

I propose to adjust the behavior so that the "parallel group" line
prints the test names before/as the tests are started, and then the
subsequent lines print the results after the tests finish, as is
currently the case.

See attached patch.

Attachment Content-Type Size
pg_regress-parallel.patch text/x-patch 1.1 KB

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: parallel regression test output
Date: 2010-01-17 21:05:18
Message-ID: 7650.1263762318@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> I propose to adjust the behavior so that the "parallel group" line
> prints the test names before/as the tests are started, and then the
> subsequent lines print the results after the tests finish, as is
> currently the case.

This is not actually going to work nicely in cases such as the number of
parallel tests being limited by max_connections. Personally I never
found the current behavior objectionable ...

regards, tom lane


From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: parallel regression test output
Date: 2010-01-17 23:25:34
Message-ID: 13913.1263770734@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

I wrote:
> This is not actually going to work nicely in cases such as the number of
> parallel tests being limited by max_connections.

Er, no, I take that back: I was thinking that the status() function
included checking of the output file, but it only prints the test name.

Still, I'm not convinced this is an improvement. The current behavior
gives some feedback about how the set of parallel tests is progressing,
while what you suggest would typically just print all the test names
right away and then sit there for a long time.

regards, tom lane


From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: parallel regression test output
Date: 2010-01-18 04:54:10
Message-ID: 603c8f071001172054p8943e37ue756c960278654cf@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Sun, Jan 17, 2010 at 3:19 PM, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
> There is something slightly funny about the regression test output.
> When it starts a parallel group, it prints something like
>
> parallel group (14 tests):  select_views portals_p2 rules foreign_key
> cluster dependency guc bitmapops combocid tsearch tsdicts foreign_data
> window xmlmap
>
> One would think that it prints this as the tests are started, but it
> actually prints it as the tests finish.

I always assumed that it was printing the names as the tests finished,
probably because of the way the output is staggered. If they were
printed when the tests were started, the list would be printed all but
simultaneously.

> The last one or two test names
> are always printed after a considerable delay, probably because of
> terminal timing issues, which I have found confusing on several
> occasions.

Terminal timing issues?

> I propose to adjust the behavior so that the "parallel group" line
> prints the test names before/as the tests are started, and then the
> subsequent lines print the results after the tests finish, as is
> currently the case.

I think I prefer the current behavior. As Tom said downthread, it
gives you a sort of progress indicator.

...Robert


From: Peter Eisentraut <peter_e(at)gmx(dot)net>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: parallel regression test output
Date: 2010-01-18 21:54:18
Message-ID: 1263851658.24310.4.camel@vanquo.pezone.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On sön, 2010-01-17 at 23:54 -0500, Robert Haas wrote:
> I always assumed that it was printing the names as the tests finished,
> probably because of the way the output is staggered. If they were
> printed when the tests were started, the list would be printed all but
> simultaneously.

Well, as long as someone expects it to be that way, then I guess that'd
be OK. I am concerned about an inconsistency with the serial tests that
go

test foo ... <pause>ok

whereas with the parallel tests don't give any indication what test has
started.


From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: pgsql-hackers(at)postgresql(dot)org
Subject: Re: parallel regression test output
Date: 2010-01-19 00:49:59
Message-ID: 603c8f071001181649p34459e9aq15481cac8f8a16ed@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

On Mon, Jan 18, 2010 at 4:54 PM, Peter Eisentraut <peter_e(at)gmx(dot)net> wrote:
> On sön, 2010-01-17 at 23:54 -0500, Robert Haas wrote:
>> I always assumed that it was printing the names as the tests finished,
>> probably because of the way the output is staggered.  If they were
>> printed when the tests were started, the list would be printed all but
>> simultaneously.
>
> Well, as long as someone expects it to be that way, then I guess that'd
> be OK.  I am concerned about an inconsistency with the serial tests that
> go
>
> test foo ... <pause>ok
>
> whereas with the parallel tests don't give any indication what test has
> started.

I always thought of the words "parallel group (x tests)" as being
parallel to printing "test foo ..." -- though admittedly that doesn't
give you specific information about which tests are starting at which
time. We certainly could design some system where we signal
beginnings and ends of tests, but I'm not sure it's worth cluttering
the output. Ordinarily I suspect they all go so fast that it doesn't
matter much.

...Robert