On Mon, Mar 24, 2025 at 10:10:44AM -0500, Justin Tobler wrote: > On 25/03/24 11:40AM, Patrick Steinhardt wrote: > > That wouldn't help with the fixed bug though, which is that we call > > abort after a failed commit even though the transaction was already > > aborted. > > I wonder if it would make sense to stop closing the transaction on a > failed commit and require the caller to abort it. This would allow error > handling to unconditionally abort the transaction during cleanup. I think it might still feel somewhat awkward because now every caller would have to both abort and free the transaction when the commit fails. An alternative could be to make abortion idempotent, where aborting an already aborted transaction is fine. But I'm not too sure whether that would significantly improve things. I don't really have a gut feeling here what the best route to go would be. Patrick