model-writtenrun 7480 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
Aug 2020 - Jan 2021 · 8 entries
- Alvaro Herrera proposed a two-transaction DETACH PARTITION CONCURRENTLY implementation and its ALTER TABLE relation-pointer prerequisite in #1, retaining ordinary DETACH because concurrent detach cannot run inside a transaction block or with a default partition.
- Alvaro explained FINALIZE recovery after cancellation or crashes and the replacement CHECK constraint in #3; Robert Haas questioned visibility and plan lifetime in #4 and #6, prompting the lock-wait and planner/executor explanation in #8.
- Hao Wu's testing exposed disappearing rows under REPEATABLE READ in #7, leading Alvaro to preserve detached partitions during snapshot-isolation planning in #11.
- Hao separately reported incorrect default-partition routing during ATTACH in #9; Amit Langote moved that work to thread #42894 in #10, where the later submissions produced f481d28232.
- Amit's reviews in #13 and #15 exposed argument-order mistakes, duplicate constraints, and inserts routed into partitions that subsequent reads could not see; #21 revised tuple routing and partition-parent lookup while retaining detached partitions where old plans required them.
- Andy Fan proposed NOWAIT-style behavior in #17, but Alvaro and David Rowley explained in #18 and #19 that avoiding the exclusive parent lock was necessary for continuously busy tables.
- Alvaro added stronger temporary partition locking, snapshot-aware tuple routing, FINALIZE waiting, and exact duplicate-constraint avoidance in #22.
- Justin Pryzby's review and concurrent attach/detach tests in #25 found bogus CHECK constraints; after the revised submission #28, Justin supplied a session-lock fix in #29, which Alvaro declined in #30 because cancellation or crashes could still release the protection.
Feb - May 2021 · 16 entries
- After rebasing in #30 and #31, Alvaro added pending-detach command checks, cancellation tests, and the inhdetachpending name in #33, while noting that psql completion remained missing.
- Justin still reproduced broken constraints in #34; Alvaro supplied a partition-parent lookup correction in #35, and Justin confirmed that it fixed the reported constraints while advocating implication-based redundancy checks in #36.
- Alvaro discovered a foreign-key violation under REPEATABLE READ in #44 and traced it to blanket isolation-level visibility rules in #45; #47 instead checked the pg_inherits tuple's xmin against the active snapshot.
- The prerequisite from #47 landed unchanged as cd03c6e94b, followed by the feature as 71f4c8c6f7 with additional cursor and foreign-key tests, documentation, and helper cleanup, announced in #48.
- Alvaro confirmed in #49 that the landed implementation restored ShareUpdateExclusive locking on the partition because stronger locking had not solved the foreign-key problem.
- Tom Lane reported a cache-clobbering buildfarm failure in #50; Alvaro recognized the expected output was wrong in #52, and Amit diagnosed snapshot-dependent descriptor reuse in #54 and supplied #55.
- Justin separately submitted implication-based CHECK avoidance in #51; Alvaro corrected its constraint representation and committed it as 7b357cc6ae, confirming reattachment behavior in #62.
- Alvaro reworked Amit's cache fix into uncached snapshot-dependent descriptors in #59, tried a second cached descriptor in #60, then abandoned that unsafe experiment and added PortalContext lifetime management in #61.
- After Amit requested consistent API naming and clearer comments in #63, both patches from #61 landed together as 8aba932251, with joint authorship acknowledged.
- Amit demonstrated severe repeated descriptor construction and memory growth with many partitions in #65; Alvaro revived caching in #67, using the detached tuple's xmin to validate reuse and proposing only one pending detach per parent.
- The revisions in #70 and #71 enforced the single-pending-detach restriction, but Amit found missing cache resets, stale descriptors, crashes, and a PortalContext leak in #72 and #73.
- Alvaro introduced separate descriptor memory contexts in #75, added regression coverage in #76, and applied Amit's final review from #77 in #78; that version landed as d6b8d29419 with an additional documentation sentence.
- Amit corrected the classification of descriptors that did not actually omit a partition in #80; this landed with a small invariant-check cleanup as 3fe773b149, while #84 and #87 acknowledged a remaining transient REPEATABLE READ performance issue.
- Pavel Luzanov reported outdated locking documentation in #81, Amit supplied #82, and Alvaro revised its examples, wording, and link presentation before landing db6e1aeb95, as explained in #86.
- Noah Misch collected remaining buildfarm failures in #88, and Amit reported successful cache-clobbering tests in #89; Alvaro distinguished historical failures from cancellation-output races in the final message #90.
- The final discussion produced eb43bdbf51, adding cancellation synchronization to the fourth isolation suite; the feature and submitted follow-up fixes had landed, with further buildfarm observation needed and the acknowledged transient performance limitation still unresolved.