model-writtenrun 7388 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Yura Sokolov reported that an extended-protocol SELECT FOR UPDATE could retain a buffer pin and block VACUUM, and proposed an inline PortalDrop call when execution completes in #1.
- Tom Lane rejected automatic portal destruction as contrary to the wire protocol in #2; after Alvaro Herrera opposed unconditional libpq portal closure in #4, Tom suggested investigating why a completed executor retained buffer pins in #5.
- Yura argued that pipelined PQsendQuery should preserve ordinary PQsendQuery semantics in #6 and #7; Alvaro accepted that narrower argument in #8 and attached a patch adding Close Portal and trace updates in #10, while leaving PQsendQueryParams and PQsendQueryPrepared unchanged.
- Tom questioned error-case equivalence in #11 but raised no blocking objection, and later confirmed that matching exec_simple_query's PortalDrop behavior made the pipeline change necessary in #13.
- Tom traced the original buffer-pin problem to LockRows leaving its EvalPlanQual sub-executor active after EOF and posted the independent shutdown fix in #12.
- The executor fix landed unchanged from #12 as bb4aed46a5, without backpatching because the longstanding problem had few reports and limited consequences.
- Yura renewed the proposal to close portals in PQsendQueryParams and PQsendQueryPrepared in #15, but Tom rejected changing their established behavior in #16, pointing to the executor fix as the solution and leaving its possible backpatching open for discussion.
- The pipeline patch landed unchanged from #10 as 4efcf47053, and Alvaro confirmed the push in #17; both attached patches were committed, while broader libpq portal closure was rejected and no backpatch decision followed.