jenkins-bot has submitted this change and it was merged. Change subject: Revert "AuthManager: Commit transaction after auto-creating a user" ......................................................................
Revert "AuthManager: Commit transaction after auto-creating a user" * 81be9512a022 should obviate the main desire for this. The normal commit step is now relied upon again. * 820f5d6ce57f and a26fbb67054 enforce DBO_TRX transactions. * Committing the implicit transaction(s) prematurely is bad for web request and cross-DB transactionality. Only code that has clear outermost DB context (e.g. jobs/maintenance) should be doing things like this as it becomes hard to reason about (e.g. how much the request/caller needs atomicity or whether there is an outer (start|end)Atomic section). This reverts commit 83c66caa0831086db7c2033ddda38106584060d0. Change-Id: I1a5533b239e53f2089f239651c6fdf97e51c9062 --- M includes/auth/AuthManager.php 1 file changed, 1 insertion(+), 5 deletions(-) Approvals: Gergő Tisza: Looks good to me, approved jenkins-bot: Verified diff --git a/includes/auth/AuthManager.php b/includes/auth/AuthManager.php index 50e370e..b4ce16f 100644 --- a/includes/auth/AuthManager.php +++ b/includes/auth/AuthManager.php @@ -1688,12 +1688,8 @@ $logEntry->setParameters( [ '4::userid' => $user->getId(), ] ); - $logid = $logEntry->insert(); + $logEntry->insert(); } - - // Commit database changes, so even if something else later blows up - // the newly-created user doesn't get lost. - wfGetLBFactory()->commitMasterChanges( __METHOD__ ); $trxProfiler->setSilenced( false ); -- To view, visit https://gerrit.wikimedia.org/r/300686 To unsubscribe, visit https://gerrit.wikimedia.org/r/settings Gerrit-MessageType: merged Gerrit-Change-Id: I1a5533b239e53f2089f239651c6fdf97e51c9062 Gerrit-PatchSet: 6 Gerrit-Project: mediawiki/core Gerrit-Branch: master Gerrit-Owner: Aaron Schulz <asch...@wikimedia.org> Gerrit-Reviewer: Aaron Schulz <asch...@wikimedia.org> Gerrit-Reviewer: Anomie <bjor...@wikimedia.org> Gerrit-Reviewer: Gergő Tisza <gti...@wikimedia.org> Gerrit-Reviewer: Gilles <gdu...@wikimedia.org> Gerrit-Reviewer: Zppix <supp...@zppixballee.com> Gerrit-Reviewer: jenkins-bot <> _______________________________________________ MediaWiki-commits mailing list MediaWiki-commits@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits