pg.ddx.io  pgsql-hackers@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Peter Eisentraut <peter.eisentraut@2ndquadrant.com>
Cc: Amit Kapila <amit.kapila16@gmail.com>
Cc: Noah Misch <noah@leadboat.com>
Cc: Clément Prévost <prevostclement@gmail.com>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Subject: Re: parallel.c is not marked as test covered
Date: Mon, 20 Jun 2016 13:13:34 -0400
Message-ID: <29552.1466442814@sss.pgh.pa.us> (raw)
In-Reply-To: <CA+TgmoZfTM0H9mQm2T0hQ7pORstfyJvfrELeBvZpqo7Uv8t9Tg@mail.gmail.com>
References: <CAKJS1f-3evRXNfTh7GLFGfCkXhxOs0G5PJ_JQ7EbJYnsgK61yw@mail.gmail.com>
	<20160607052716.GA766951@tornado.leadboat.com>
	<b580fe7b-237f-f396-8abd-317475328641@2ndquadrant.com>
	<CABaKae-eCW4d7SmgxoA8oBan5hhRnb0_qmHtQ580ANfPPNo8tw@mail.gmail.com>
	<20160608034342.GA804701@tornado.leadboat.com>
	<58cd047c-deba-0863-b279-56b931237176@2ndquadrant.com>
	<CA+Tgmoac+sysZi0QKtexCKwQ99fjiwfrbQJ4aom-i1C0s6SeAg@mail.gmail.com>
	<CA+Tgmob78-4NEYsqA7mapdqLgkAyVuOAKmtgQH9qiMhand-acg@mail.gmail.com>
	<bfd204ab-ab1a-792a-b345-0274a09a4b5f@2ndquadrant.com>
	<CA+TgmoYBiBJFcPUFS+R8XN7_DCf5jhQvyopsS6C1y-6EYjBiLw@mail.gmail.com>
	<CA+TgmoaJGJ6DPjWPwwVzbNYW6Aj5f33gYuwU3eg13g=f5wqGXw@mail.gmail.com>
	<b99734a7-4e40-af77-054a-b6c1409d9ef1@2ndquadrant.com>
	<24863.1466311214@sss.pgh.pa.us>
	<CAA4eK1LEe+jJUvQa3p3LEt5eckO4Fr=YyxynaUYm-eB35T0cxQ@mail.gmail.com>
	<13382.1466350602@sss.pgh.pa.us>
	<CA+TgmoaDFcbhNLvS+h+2=oEiAwza8AoKrtC76hn1DEk7Pz_BuQ@mail.gmail.com>
	<CA+TgmobeA=8StbgxgRAfyYG-A-FUmZQQ4nc953cd7Ar! DRpyGAg@mail.gmail.com>
	<31689.1466389410@sss.pgh.pa.us>
	<CA+TgmoZfTM0H9mQm2T0hQ7pORstfyJvfrELeBvZpqo7Uv8t9Tg@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>

Robert Haas <robertmhaas@gmail.com> writes:
> On Sun, Jun 19, 2016 at 10:23 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> Personally, I'm +1 for such tinkering if it makes the feature either more
>> controllable or more understandable.  After reading the comments at the
>> head of nodeGather.c, though, I don't think that single_copy is either
>> understandable or useful, and merely renaming it won't help.  Apparently,
>> it runs code in the worker, except when it doesn't, and even when it does,
>> it's absolutely guaranteed to be a performance loss because the leader is
>> doing nothing.  What in the world is the point?

> The single_copy flag allows a Gather node to have a child plan which
> is not intrinsically parallel.

OK, but I'm very dubious of your claim that this has any use except for
testing purposes.  It certainly has no such use today.  Therefore, the
behavior of falling back to running in the leader seems like an
anti-feature to me.  If we want to test running in a worker, then we
want to test that, not maybe test it.

I propose that the behavior we actually want here is to execute in
a worker, full stop.  If we can't get one, wait till we can.  If we
can't get one because no slots have been allocated at all, fail.
That would make the behavior deterministic enough for the regression
tests to rely on it.

And while I don't know what this mode should be called, I'm pretty sure
that neither "single_copy" nor "pipeline" are useful descriptions.

			regards, tom lane


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers



view thread (71+ messages)  latest in thread

Message-ID: <29552.1466442814@sss.pgh.pa.us>
Permalink:  ../29552.1466442814@sss.pgh.pa.us/
Also on:    postgresql.org/message-id/29552.1466442814@sss.pgh.pa.us

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients from your mail client; the link fills in
  the headers below: reply via email
  Some clients, webmail especially, drop In-Reply-To and References from
  a link, and the reply then starts a new thread: use the mbox below.

  To: pgsql-hackers@postgresql.org
  Cc: tgl@sss.pgh.pa.us, robertmhaas@gmail.com, peter.eisentraut@2ndquadrant.com, amit.kapila16@gmail.com, noah@leadboat.com, prevostclement@gmail.com
  Subject: Re: parallel.c is not marked as test covered
  In-Reply-To: <29552.1466442814@sss.pgh.pa.us>
  References: <CAKJS1f-3evRXNfTh7GLFGfCkXhxOs0G5PJ_JQ7EbJYnsgK61yw@mail.gmail.com> <CABaKae-eCW4d7SmgxoA8oBan5hhRnb0_qmHtQ580ANfPPNo8tw@mail.gmail.com> <20160608034342.GA804701@tornado.leadboat.com> <58cd047c-deba-0863-b279-56b931237176@2ndquadrant.com> <CA+Tgmoac+sysZi0QKtexCKwQ99fjiwfrbQJ4aom-i1C0s6SeAg@mail.gmail.com> <CA+Tgmob78-4NEYsqA7mapdqLgkAyVuOAKmtgQH9qiMhand-acg@mail.gmail.com> <bfd204ab-ab1a-792a-b345-0274a09a4b5f@2ndquadrant.com> <CA+TgmoYBiBJFcPUFS+R8XN7_DCf5jhQvyopsS6C1y-6EYjBiLw@mail.gmail.com> <CA+TgmoaJGJ6DPjWPwwVzbNYW6Aj5f33gYuwU3eg13g=f5wqGXw@mail.gmail.com> <b99734a7-4e40-af77-054a-b6c1409d9ef1@2ndquadrant.com> <24863.1466311214@sss.pgh.pa.us> <CAA4eK1LEe+jJUvQa3p3LEt5eckO4Fr=YyxynaUYm-eB35T0cxQ@mail.gmail.com> <13382.1466350602@sss.pgh.pa.us> <CA+TgmoaDFcbhNLvS+h+2=oEiAwza8AoKrtC76hn1DEk7Pz_BuQ@mail.gmail.com> <31689.1466389410@sss.pgh.pa.us> <CA+TgmoZfTM0H9mQm2T0hQ7pORstfyJvfrELeBvZpqo7Uv8t9Tg@mail.gmail.com> <29552.1466442814@sss.pgh.pa.us>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox