Re: On disable_cost
Laurenz Albe <laurenz.albe@cybertec.at>
From: Laurenz Albe <laurenz.albe@cybertec.at>
To: Alena Rybakina <a.rybakina@postgrespro.ru>
Cc: David Rowley <dgrowleyml@gmail.com>, Robert Haas
<robertmhaas@gmail.com>, Tom Lane <tgl@sss.pgh.pa.us>, Heikki Linnakangas
<hlinnaka@iki.fi>, Peter Geoghegan <pg@bowt.ie>, PostgreSQL Hackers
<pgsql-hackers@lists.postgresql.org>
Date: 2024-10-02T19:08:03Z
Lists: pgsql-hackers
On Wed, 2024-10-02 at 21:31 +0300, Alena Rybakina wrote: > Honestly, I like this patch. Before this patch, when disabling any algorithm > in the optimizer, the cost increased significantly and I’m not sure that this > was a reliable solution due to the fact that the cost even without disabling > can be greatly increased because of the high cardinality, for example. > > Right there, the mechanism is simple and more honest in my opinion - we simply > count the number of disabled nodes and discard the paths with the largest > number of them. I have no issue with this way of handling disabled plan nodes, I only complained about the verbosity of the EXPLAIN output. I don't want to see disabled nodes propagated all the way up the tree, and I would like the output suppressed by default. Yours, Laurenz Albe
Commits
-
Doc: add detail about EXPLAIN's "Disabled" property
- 84b8fccbe5c2 18.0 landed
-
Adjust EXPLAIN's output for disabled nodes
- 161320b4b960 18.0 landed
-
Fix order of parameters in a cost_sort call
- 87b6c3c0b703 18.0 landed
-
Show number of disabled nodes in EXPLAIN ANALYZE output.
- c01743aa4866 18.0 landed
-
Treat number of disabled nodes in a path as a separate cost metric.
- e22253467942 18.0 landed
-
Remove grotty use of disable_cost for TID scan plans.
- e4326fbc60c4 18.0 landed