model-writtenrun 1199 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Induja Sreekanthan reported that high effective_io_concurrency lets a temporary-table sequential scan pin every local buffer, leaving none for TOAST access, and proposed a 75% buffer cap plus a temporary-table I/O concurrency cap #1.
- Eduard Stepanov supplied an alternative implementation that checks the remaining pin budget during look-ahead, starts pending reads when that budget is exhausted, and adds two regression scenarios #2.
- Feike Steenbergen reported the same failure in production after upgrading to PostgreSQL 18, initially suspected io_uring, and then found that switching to worker I/O did not eliminate it #3 #4.
- Xuneng Zhou connected the failure to an existing development-branch fix that limits local pins to one quarter of the pool and successfully tested backpatching it to PostgreSQL 18 #5; subsequent testing showed that PostgreSQL 19 could pass the reproducer even without that fix, prompting further investigation #6 #7.
- Xuneng reproduced the PostgreSQL 18 failure with all three I/O methods and traced it to TOAST requesting another buffer while look-ahead held the entire local pool #8; Feike later confirmed failures across all I/O methods and reported continuing production failures after an upgrade he described as PostgreSQL 19, for which Xuneng requested logs, settings, and workload details #9 #10.
- Melanie Plageman endorsed backpatching the existing quarter-pool fix to PostgreSQL 18 and raised a possible future formula allocating one quarter of remaining buffers #11; Xuneng cautioned that this could let successive streams approach exhaustion by removing the aggregate hard cap #12.
- Melanie committed the discussed backpatch as ed8050370b, changing local pin-limit helpers rather than adopting either attachment or its tests, and explained that PostgreSQL 17 was excluded because ordinary sequential scans cannot grow look-ahead enough to trigger the reported failure and the fix would require different code #13.
- Melanie deferred further changes to the pin-budget formula until concrete workloads justify them #14, and Xuneng agreed with the backpatch decision #15.
- The original PostgreSQL 18 fix had landed by the thread's end, while Feike's later production report had no demonstrated resolution here; Xuneng proposed discussing a separate synchronous-I/O look-ahead optimization and then corrected part of his reasoning, without submitting another patch #16 #17.