Convert page creation to using startAtomic()/endAtomic()
authorAaron Schulz <aschulz@wikimedia.org>
Sun, 13 Dec 2015 12:01:03 +0000 (04:01 -0800)
committerAaron Schulz <aschulz@wikimedia.org>
Wed, 27 Jan 2016 19:38:05 +0000 (11:38 -0800)
commit36a87a890291b651d332c510ed9ed791472e4f44
tree571a78cec2ca1ff2b27a1e50b348a82ea3c87ab5
parent5cd57713f23a52fc9812a94087d9aa2756a97331
Convert page creation to using startAtomic()/endAtomic()

A few semantic changes result from this:

* If multiple pages are created in a request, the updates happen
  in the same order relative to each other, but all in one second
  step instead of after each page edit.
* If an extension set some extra Status info or errors via the
  PageContentInsertComplete hook, they will not be seen by the
  caller (unless it was a CLI script possibly). Few callers use
  $status at all, and I did not see any that mutated it. Since
  the page is already committed when this hooks run (as has always
  been) they cannot veto edits and callers do not care or know what
  to do with random hook-set status errors; there was never much use
  in changing the Status anyway.

Bug: T120718
Change-Id: Ieba35056be31b2f648c57f59d19d3cbbe58f1b05
includes/db/IDatabase.php
includes/page/WikiPage.php
tests/phpunit/includes/EditPageTest.php