model-writtenrun 823 - may be wrong, links go to the source messages. Commit-by-commit LLM analysis is in the Commits dialog.
- Nikita Kalinin reported that using pgrepack through the SQL logical decoding API crashed assertion-enabled development builds #1, and Alvaro Herrera agreed that misuse should produce a friendly error #2.
- Alvaro proposed allocating plugin state during startup, letting the REPACK worker mark it with a magic number, and checking that marker at transaction begin #3; Nikita confirmed that the patch eliminated assertion failures, reported a clean ASAN run, and requested a regression test #4.
- Srinath Reddy Sadipiralla observed that the begin callback could reject misuse only after a large transaction had been decoded and buffered, so he supplied an additional patch rejecting pgrepack during SQL and replication-protocol slot creation #6.
- Antonin Houska proposed a centralized worker-identity check in logical decoding initialization #7, which Srinath incorporated with an error code and regression test #8.
- Alvaro rejected special-casing pgrepack in generic replication facilities because the restriction belonged inside the plugin #9; Antonin accepted that reasoning and deferred a possible reserved-slot API as unsuitable for beta #10, and Srinath also agreed #11.
- Zhijie Hou suggested checking AmRepackWorker() directly in the plugin's startup callback #12, allowing Alvaro to remove the magic-number protocol while rejecting misuse early and keeping the restriction inside the plugin in his revised patch #13.
- Alvaro committed #13 with light naming, comment, assertion, and commit-message edits as cd7b204b2d, then confirmed the push #14; the fix and regression tests landed, with the generic-facility alternatives superseded.