Call ignore_user_abort() right before committing to the DB
authorAaron Schulz <aschulz@wikimedia.org>
Wed, 12 Mar 2014 21:05:33 +0000 (14:05 -0700)
committerAaron Schulz <aschulz@wikimedia.org>
Wed, 12 Mar 2014 21:05:33 +0000 (14:05 -0700)
Change-Id: I48b9e90418c38c7c9970cf0739a877b5be3a2b64

includes/Wiki.php

index d78d7cb..69cfe9d 100644 (file)
@@ -587,6 +587,9 @@ class MediaWiki {
                // Actually do the work of the request and build up any output
                $this->performRequest();
 
+               // Either all DB and deferred updates should happen or none.
+               // The later should not be cancelled due to client disconnect.
+               ignore_user_abort( true );
                // Now commit any transactions, so that unreported errors after
                // output() don't roll back the whole DB transaction
                wfGetLBFactory()->commitMasterChanges();