From: Tom Lane <tgl@sss.pgh.pa.us>
To: pgsql-committers@postgresql.org
Subject: pgsql: Rethink the GetForeignUpperPaths API (again).
Date: Fri, 01 Jul 2016 17:12:44 +0000
Message-ID: <E1bJ1zg-0004eU-6x@gemulon.postgresql.org> (raw)
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-committers>
Rethink the GetForeignUpperPaths API (again).
In the previous design, the GetForeignUpperPaths FDW callback hook was
called before we got around to labeling upper relations with the proper
consider_parallel flag; this meant that any upper paths created by an FDW
would be marked not-parallel-safe. While that's probably just as well
right now, we aren't going to want it to be true forever. Hence, abandon
the idea that FDWs should be allowed to inject upper paths before the core
code has gotten around to creating the relevant upper relation. (Well,
actually they still can, but it's on their own heads how well it works.)
Instead, adopt the same API already designed for create_upper_paths_hook:
we call GetForeignUpperPaths after each upperrel has been created and
populated with the paths the core planner knows how to make.
Branch
------
master
Details
-------
http://git.postgresql.org/pg/commitdiff/9e703987a8a1961af8edd751169a8ae1055890eb
Modified Files
--------------
doc/src/sgml/fdwhandler.sgml | 55 +++++++++++------
src/backend/optimizer/README | 13 ----
src/backend/optimizer/plan/planagg.c | 5 +-
src/backend/optimizer/plan/planner.c | 108 +++++++++++++++++++++++++++------
src/backend/optimizer/prep/prepunion.c | 4 ++
src/include/foreign/fdwapi.h | 4 +-
6 files changed, 135 insertions(+), 54 deletions(-)
--
Sent via pgsql-committers mailing list (pgsql-committers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-committers
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-committers@postgresql.org
Cc: tgl@sss.pgh.pa.us
Subject: Re: pgsql: Rethink the GetForeignUpperPaths API (again).
In-Reply-To: <E1bJ1zg-0004eU-6x@gemulon.postgresql.org>
References: <E1bJ1zg-0004eU-6x@gemulon.postgresql.org>
* 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