Re: allowing extensions to control planner behavior

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Jeff Davis <pgsql(at)j-davis(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: allowing extensions to control planner behavior
Date: 2024-08-28 23:25:59
Message-ID: 3496381.1724887559@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Jeff Davis <pgsql(at)j-davis(dot)com> writes:
> Beyond awkwardness, one case where it matters is the interaction
> between an extension that provides hints and an extension that offers a
> CustomScan. How is the hints extension supposed to disable a path it
> doesn't know about?

This does not seem remarkably problematic to me, given Robert's
proposal of a bitmask of allowed plan types per RelOptInfo.
You just do something like

rel->allowed_plan_types = DESIRED_PLAN_TYPE;

The names of the bits you aren't setting are irrelevant to you.

regards, tom lane

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Smith 2024-08-28 23:29:16 Re: Collect statistics about conflicts in logical replication
Previous Message Jeff Davis 2024-08-28 23:15:51 Re: allowing extensions to control planner behavior