pgsql: Simplify API for initially hooking custom-path providers into th

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Simplify API for initially hooking custom-path providers into th
Date: 2014-11-21 19:05:53
Message-ID: E1XrtWj-0007m0-Ec@gemulon.postgresql.org
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Simplify API for initially hooking custom-path providers into the planner.

Instead of register_custom_path_provider and a CreateCustomScanPath
callback, let's just provide a standard function hook in set_rel_pathlist.
This is more flexible than what was previously committed, is more like the
usual conventions for planner hooks, and requires less support code in the
core. We had discussed this design (including centralizing the
set_cheapest() calls) back in March or so, so I'm not sure why it wasn't
done like this already.

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/c2ea2285e978d9289084846a3343cef7d261d880

Modified Files
--------------
src/backend/optimizer/path/allpaths.c | 48 ++++++++++++++-------------------
src/backend/optimizer/util/pathnode.c | 48 ---------------------------------
src/include/nodes/relation.h | 3 ---
src/include/optimizer/pathnode.h | 9 -------
src/include/optimizer/paths.h | 7 +++++
5 files changed, 27 insertions(+), 88 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2014-11-21 23:21:52 pgsql: Rearrange CustomScan API.
Previous Message Andrew Dunstan 2014-11-21 17:41:36 pgsql: Fix an error in psql that overcounted output lines.