Session

Back

Debugging the Postgres Planner

Date: 2018-09-06
Time: 23:00 - 23:50
Room: Market Street
Level: Intermediate
Feedback: Leave feedback

Once you've ruled out all of the obvious causes of bad plans--unanalyzed tables, lack of indexes, etc. it's time to dive into the code and find the root cause. This session will cover the process of debugging a bad plan starting from the explain output through hacking in a fix and recompiling the database. Topics covered will include: characteristics of a plan and how these map to components in Postgres code, strategies for producing a minimal repro, simple heuristics for developing a reference plan, using the debugger along with several GUCs to examine the plan tree throughout planning, and, finally, adding in your own code.

Speaker

Melanie Plageman