Re: RFC: extensible planner state

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Tom Lane <tgl@sss.pgh.pa.us>
Cc: PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2025-10-07T17:19:14Z
Lists: pgsql-hackers

Attachments

On Mon, Sep 29, 2025 at 9:28 AM Robert Haas <robertmhaas@gmail.com> wrote:
> Oh, nice, thanks! I'm going to be on vacation the rest of this week so
> I plan to deal with this next week. However, if you feel like
> committing it before then, please feel free.

I committed 0001 and 0002. That left three remaining patches. I merged
your (Tom's) comment changes into the first of those, and here's the
result of that.

-- 
Robert Haas
EDB: http://www.enterprisedb.com

Commits

  1. Add extension_state member to PlannedStmt.

  2. Add planner_setup_hook and planner_shutdown_hook.

  3. Add ExplainState argument to pg_plan_query() and planner().

  4. Remove PlannerInfo's join_search_private method.

  5. Allow private state in certain planner data structures.

  6. Fix array allocation bugs in SetExplainExtensionState.

  7. Make it possible for loadable modules to add EXPLAIN options.