model-writtenrun 4424 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
Jan 2020 · 2 entries
- Andres Freund opened the discussion because buffers_backend mixed unavoidable extensions, strategy writes, and other backend activity, making it unreliable for tuning bgwriter and checkpointer behavior #1.
- Magnus Hagander supported broader counters, while Andres proposed per-process shared counters aggregated on demand and atomic reads and writes that avoided contended increments #2 #3 #5.
Apr 2021 · 1 entry
- Melanie Plageman supplied the first implementation using PgBackendStatus counters and shared totals for exited backends, then adopted Andres's proposal for one view row per backend type and block-sized extension counts #7 #8 #9.
Aug 2021 - Jan 2022 · 8 entries
- After adding atomic counters, Melanie replaced separate persistence with statistics-collector reporting at Andres's request, preserving the existing bgwriter pacing counter and separating legacy-column removal from the new view #11 #12 #13 #16.
- An attempted checkpointer-reporting delta exposed duplicate accounting and missing auxiliary-process handling, so the next full series moved reporting into the common shutdown hook #17 #18 #19.
- Alvaro Herrera proposed expressing shared, strategy, and local activity as another row dimension, which Melanie implemented together with reset accounting for live backend counters #20 #21.
- The next revisions added bootstrap initialization, split oversized reset messages by backend type, and renamed the concepts IOOp and IOPath to describe their meaning more clearly #22 #24 #27.
- Melanie supplied incremental accounting fixes and Thomas Munro's counter helper, while Andres requested that the generic tuplestore utility be developed separately; the next full series incorporated those decisions #29 #30 #31.
- The unchanged bootstrap prerequisite from #31 landed as 3b34645678, and Melanie split the remaining work into smaller reviewable patches #32 #33.
- Justin Pryzby's reviews found backend traversal, accumulation, reset initialization, and single-user problems, which Melanie corrected before reporting successful check-world testing #34 #35 #38 #39 #40 #41.
- Melanie added a standalone backend type and experimented with a separate checkpointer view and more bgwriter counters, then withdrew those extra features to simplify the series and retain the legacy view #47 #48 #49.
Feb - Apr 2022 · 1 entry
- After rebases by Melanie and Justin, the arrival of cumulative shared-memory statistics prompted a major rewrite using backend-local pending counters flushed into shared aggregates, replacing the old collector-based design #50 #52 #53.
Jul 2022 - Apr 2023 · 25 entries
- Andres and Kyotaro Horiguchi reviewed locking, reporting, ring-origin handling, local allocations, and invalid combinations; subsequent revisions added reads, expanded tests, and established per-backend-type locking and a common reset timestamp #54 #56 #58 #63 #64.
- The standalone-backend and redundant-WAL-reporting prerequisites from #70 landed unchanged as 0c679464a8 and 1bdd54e662, leaving the IO feature in a smaller remainder series #71 #73.
- Lukas Fittl and Maciek Sakrejda paired on a review that prompted separate vacuum, bulkread, and bulkwrite contexts, clearer units, and experimental buffer-hit counts #75 #77.
- Further revisions distinguished ring reuse from acquisition, then explored eviction, freelist acquisition, rejection, and repossession counts while correcting strategy accounting #79 #83 #90.
- The design was narrowed by dropping disputed acquisition and rejection-related counters and adding an independent IOObject dimension for permanent and temporary relations, with op_bytes identifying operation units #89 #91 #93.
- Maciek supplied a documentation-only delta, Justin investigated compilation and ring-behavior issues, and Melanie incorporated their feedback while moving bulkread coverage into amcheck SQL tests #94 #96 #98 #100.
- Andres reorganized the implementation into cleanup, infrastructure, relation counting, and view components; Melanie incorporated his branch, corrected fsync accounting, and simplified counters into multidimensional arrays #106 #107 #108 #109.
- Samay Sharma coauthored a documentation rewrite that separated column definitions from interpretation and removed misleading equivalence claims about other statistics views, while Justin's review added missing local-buffer coverage and corrected naming #110 #112 #113.
- Andres's cleanup prerequisite, forwarded in #115, landed unchanged as 250c8ee07e, and the next submission carried only the remaining IO work #116 #118.
- The remaining revisions fixed statistics-kind lookup, refined validation and tests, and consistently ordered backend type, object, context, and operation after Andres explained the hierarchy's locking and future-extension benefits #118 #119 #120.
- Melanie added reusable regression tablespace setup to support deterministic relation rewrites, then removed an accidental duplicate FlushBuffer() call and fixed tablespace-test ordering #123 #124.
- Kyotaro reviewed the final infrastructure and view, questioning assertions, naming, null handling, and operation units; Andres defended the validation and the need to accommodate future non-block IO #125 #127 #128.
- After another complete review, Andres polished tablespace setup, separated tests from the view, and made formatting adjustments before declaring the series ready #129.
- The infrastructure and relation instrumentation from #124 landed as 28e626bde0 and f30d62c2fc, with only infrastructure formatting and the statistics-file version adjustment.
- The view and documentation from #124 landed as a9c70b46db, with tests separated and a catalog-version bump.
- The reusable tablespace prerequisite and extracted tests from #124 landed as 9c83bbcf7e and 10a082bf72, omitting unnecessary tablespace query rewrites and adding test-table cleanup #132.
- The landing retained legacy pg_stat_bgwriter statistics for compatibility and left buffer hits, WAL IO, bypass IO, per-connection statistics, and IO timing for later work a9c70b46db #131.
- After landing, Andres proposed shorter object and context column names, while Justin investigated apparently impossible backend/context combinations and confirmed that autovacuum bulk reads could occur #133 #134 #135 #136 #137.
- Tom Lane reported compiler warnings from enum comparisons and misleading FIRST macros; after discussion of cast-based alternatives, Melanie supplied macro removal and integer-loop patches that Tom combined unchanged into 728560db7d #138 #139 #147 #148 #149.
- Remaining warnings in three enum range assertions required unsigned casts in b1b86820d8, completing another part of the compiler problem originally reported in #138.
- Tom then reported intermittent reads-test failures, and Kyotaro traced them to concurrent autoanalyze and proposed disabling autovacuum on the test table #152 #153 #154.
- Andres argued that transaction locking would protect against all concurrent readers while preserving other coverage, so Melanie replaced the workaround, Kyotaro manually tested it, and Andres committed the transaction-based fix with comment edits as 1be0fdb9de #156 #158 #159 #160.
- Justin reported a separate writes-test failure caused by dirty buffers being written in strategy contexts before the normal-context check, prompting #164 to broaden counting and sample earlier; that patch landed unchanged as ef719e7b32 #162 #163 #166.
- Pavel Luzanov discovered that the visible standalone backend type lacked documentation, prompting Melanie's patch and Pavel's revised explanation of cluster initialization and single-user mode #167 #168 #171.
- The thread ends with the main feature and regression fixes committed, while the standalone-backend documentation still awaits a committer and a small wording adjustment requested by Melanie and reiterated by Pavel #172 #173.