jenkins-bot [Fri, 13 May 2016 21:52:23 +0000 (21:52 +0000)]
Merge "Remove support for $wgWellFormedXml=false"
jenkins-bot [Fri, 13 May 2016 21:49:26 +0000 (21:49 +0000)]
Merge "Require strip marker names to not have & ' " < or > in them"
jenkins-bot [Fri, 13 May 2016 21:36:57 +0000 (21:36 +0000)]
Merge "OOUIHTMLForm: Don't output an empty hidden LabelWidget if not needed"
jenkins-bot [Fri, 13 May 2016 21:35:37 +0000 (21:35 +0000)]
Merge "Batch links updates performed by refreshLinks jobs"
Arlo Breault [Fri, 13 May 2016 20:35:10 +0000 (13:35 -0700)]
Sync up with Parsoid parserTests.
This now aligns with Parsoid commit
b692ba97df11a20978c155e2316578aac2ac973d
Change-Id: I659eb045b106d8c48177f546448ddb80e0fdb2a9
Translation updater bot [Fri, 13 May 2016 19:58:36 +0000 (21:58 +0200)]
Localisation updates from https://translatewiki.net.
Change-Id: I3bb9af58b7d0a958bf1fc46e75e185f390b3fc65
jenkins-bot [Fri, 13 May 2016 19:48:31 +0000 (19:48 +0000)]
Merge "Add LinkCache::getSelectFields() and use it in a few places"
jenkins-bot [Fri, 13 May 2016 19:48:17 +0000 (19:48 +0000)]
Merge "Warn when a restricted displaytitle is ignored"
jenkins-bot [Fri, 13 May 2016 19:46:05 +0000 (19:46 +0000)]
Merge "LinkHolderArray: Title::makeTitle() does not return null"
jenkins-bot [Fri, 13 May 2016 19:41:58 +0000 (19:41 +0000)]
Merge "LinkHolderArray: Use LinkBatch for generating WHERE in query"
Florian [Sun, 8 May 2016 14:55:34 +0000 (16:55 +0200)]
OOUIHTMLForm: Don't output an empty hidden LabelWidget if not needed
The hidden element is only needed if either a header is set or the form
has errors. If both does not apply, the element isn't needed and should
be omitted instead of hidden with `display:none`.
It's also not needed to add a LabelWidget for the header, if the form has
errors, only, but no header (which would result in an empty space between
the header and the fieldset legend).
Follow up: Ifbf38878d41906184f97169b22002f788711a311
Change-Id: I4ffefdc50d435590d25a7dfc202228920dd801ae
Aaron Schulz [Wed, 4 May 2016 22:05:03 +0000 (15:05 -0700)]
Batch links updates performed by refreshLinks jobs
This should avoid erratic lag spikes that happen as many links are
added and removed via new pages (sometimes bot generated) and edits
that blank pages as well as their reversions.
In the common cases of a modest number of link changes, the entire
update will still happen in one transaction. In any case, link updates
now use a lock to avoid clobbering each other on the same page.
Bug: T109943
Change-Id: Icd453fcc3d28342065893260ad327eae11870245
jenkins-bot [Fri, 13 May 2016 15:54:30 +0000 (15:54 +0000)]
Merge "mediawiki.jqueryMsg: Fix 'asciiAlphabetLiteral' definition"
Kunal Mehta [Fri, 13 May 2016 07:00:39 +0000 (00:00 -0700)]
Add LinkCache::getSelectFields() and use it in a few places
Change-Id: Ic65b20cc2aa41f9b481e280918fe95c57da53221
Kunal Mehta [Fri, 13 May 2016 06:27:38 +0000 (23:27 -0700)]
LinkHolderArray: Title::makeTitle() does not return null
Change-Id: I587a34459d4bcc1bae33631561fa6d4a91dfa4a5
Kunal Mehta [Fri, 13 May 2016 06:27:24 +0000 (23:27 -0700)]
LinkHolderArray: Use LinkBatch for generating WHERE in query
The entire query could be replaced with LinkBatch, but that will require
further refactoring.
Change-Id: I87cf2a391486e36e73a13baac65d243fc9196b5c
jenkins-bot [Thu, 12 May 2016 23:14:44 +0000 (23:14 +0000)]
Merge "Remove now-unused LinkCache::$instance"
jenkins-bot [Thu, 12 May 2016 23:13:17 +0000 (23:13 +0000)]
Merge "Make User::isBot() also check the "bot" right for sanity"
Kunal Mehta [Thu, 12 May 2016 23:05:19 +0000 (16:05 -0700)]
Remove now-unused LinkCache::$instance
Follows-up
449084ec4.
Change-Id: Ia43344beba0f1e5f98210d0e4e51e53e138495d1
Aaron Schulz [Thu, 12 May 2016 20:02:41 +0000 (13:02 -0700)]
Make User::isBot() also check the "bot" right for sanity
Change-Id: I835cc23719c1975bb86f642d3ede36c882ce2e9b
jenkins-bot [Thu, 12 May 2016 22:59:01 +0000 (22:59 +0000)]
Merge "Add LinkCache to MediaWikiServices"
jenkins-bot [Thu, 12 May 2016 22:58:57 +0000 (22:58 +0000)]
Merge "Follow-up
cdc93a62bf: add serialize/unserialize tests for RedisBagOStuff"
Kunal Mehta [Thu, 12 May 2016 22:44:33 +0000 (15:44 -0700)]
Add LinkCache to MediaWikiServices
LinkCache::singleton() is now deprecated, and the destroySingleton() and
setSingleton() methods were removed. They were not used in extensions,
and the usage in core was updated to use MediaWikiServices.
Change-Id: I08bb4f7913b03f71331ff683d0197c948aad6790
Matthew Flaschen [Thu, 12 May 2016 22:01:03 +0000 (18:01 -0400)]
Follow-up
cdc93a62bf: add serialize/unserialize tests for RedisBagOStuff
Bug: T134923
Change-Id: I0a7bec40c3fbf301720a248fbe21d46f5e64154c
Ori Livneh [Thu, 12 May 2016 18:10:39 +0000 (11:10 -0700)]
Decouple Xhprof profiling from profiling data processing
The motivation for this patch came from trying to use xhprof to profile the
unit tests. I was able to profile specific test suites, but if I tried to
profile a complete PHPUnit run, I ended up with empty profiling data. My
initial suspicion was that this was due to some Xhprof buffer getting
exhausted. The actual reason ended up being much simpler: the XhprofTest suite
indirectly called xhprof_enable() / xhprof_disable(), which stopped xhprof and
cleared out the data, so that when I was calling xhprof_disable() at the end of
the run, there was no profiling data to return, because xhprof was not running.
For the most part the XhprofTest was already doing the right thing by trying to
avoid having side-effects or relying on xhprof. Wherever possible, test fixture
profiling data was used in lieu of actually running xhprof. But this was not
totally successful because the Xhprof class coupled the collection of data to
the processing of data. Xhprof::__construct() called xhprof_enable(), so there
was no real way around that.
I think that the right way to fix that is to decouple profiling from profiling
data analysis. Thus I renamed 'Xhprof' to 'XhprofData', and modified the class
so that it expects to be fed profiling data rather than going out and
collecting it on its own. As a result, it is now possible to profile a full
phpunit run with xhprof, and the work that went into writing fixtures for the
Xhprof unit tests pays off: the class and the tests no longer have a hard
dependency on the xhprof extension, and the tests do not have to be skipped
when it is not installed. And the tests are really testing the system under
test, rather than the xhprof extension.
Finally, I added a new Xhprof class, which really is just an extremely thin
wrapper around xhprof_enable() / xhprof_disable(). The only extra functionality
it provides is the ability to check whether xhprof is running, via
Xhprof::isEnabled(). Calling Xhprof::enable() when it is already enabled will
cause an exception to be thrown. This should help us avoid running into
situations where two components contend for control of the profiler without
realizing it. A unit test tests this behavior.
The only part of this change that is not covered by tests is the change to
ProfilerXhprof. I tested it manually and it works.
Change-Id: Ica96beded68f04083abaf48ef1ae8c726eb60fa6
jenkins-bot [Thu, 12 May 2016 21:53:41 +0000 (21:53 +0000)]
Merge "Revert "Split editcascadeprotected permission from protect permission""
Legoktm [Thu, 12 May 2016 21:43:06 +0000 (21:43 +0000)]
Revert "Split editcascadeprotected permission from protect permission"
This doesn't make sense because 'editcascadeprotected'
effectively gives you 'protect' rights.
Furthermore, no actual usecase was provided except for a testwiki.
This reverts commit
da3464badaf9c067a4c3d98448ca72a8324e1e19.
Change-Id: I655c1af8f418369c9551db86f24fb6b66c25afdd
Brian Wolff [Wed, 20 Apr 2016 17:22:51 +0000 (13:22 -0400)]
Remove support for $wgWellFormedXml=false
tl;dr: Having unnessary complexity in security critical code is bad.
* Extra options add extra complexity and maintenance burden
** Thus we should only have one html output mode. well formed = false
was already vetoed in T52040, so lets go with WellFormed=true.
* Options which are used by very few people tend to get tested less
* Escaping is an area of code where we should be very conservative
* Having escaping rules depend on making assumptions about which
characters various browsers consider "whitespace" is scary
* $wgWellFormedXml=false has had a negative security impact in the
past (Usually not directly its fault, but has made other bugs
more exploitable)
* Saving a couple bytes (even less bytes after gzip taken into
account) is really not worth it in this context (imho).
Change-Id: I5c922e0980d3f9eb39adb5bb5833e158afda42ed
MGChecker [Sat, 30 Apr 2016 17:01:04 +0000 (19:01 +0200)]
Split off permission to delete tags from managechangetags permission
Every permission included in managechangetags is really harmless and can be reverted
in short time, except of the permission to irriversibly delete tags. That's why
this should be excluded in an additional permission that other wikis can restrict
deletechangetags more than other tag management actions.
Bug: T133811
Change-Id: Ieb9199f2c6997316ae3468ff5a92b2d2456c012f
Bartosz Dziewoński [Wed, 11 May 2016 22:24:04 +0000 (00:24 +0200)]
mediawiki.jqueryMsg: Fix 'asciiAlphabetLiteral' definition
Lack of the '^' anchor in the regex caused some inputs to
be incorrectly parsed. For example, '<b >>>="dir">asd</b>'
was parsed like '<b dir="dir">asd</b>'.
Change-Id: Iec1a13e43d2ed34a52e625bbea129454d44ba348
jenkins-bot [Thu, 12 May 2016 20:51:57 +0000 (20:51 +0000)]
Merge "Allow the signature button wikitext to be overridden locally"
jenkins-bot [Thu, 12 May 2016 20:37:00 +0000 (20:37 +0000)]
Merge "Split editcascadeprotected permission from protect permission"
jenkins-bot [Thu, 12 May 2016 20:33:25 +0000 (20:33 +0000)]
Merge "Parser tests: Also register namespace 101 to accompany 100"
jenkins-bot [Thu, 12 May 2016 20:33:21 +0000 (20:33 +0000)]
Merge "LinkCache: Use LinkTarget instead of Title"
jenkins-bot [Thu, 12 May 2016 20:33:14 +0000 (20:33 +0000)]
Merge "TitleFormatter: Match Title behavior for non-existent namespaces"
Paladox [Mon, 14 Dec 2015 19:57:39 +0000 (19:57 +0000)]
Allow the signature button wikitext to be overridden locally
Related change in wikieditor: I43f5bbaee007bbd038f2e118b3ffb8690753afb8
Bug: T26191
Change-Id: I33de58e9729a51ae73a13853ffcfcbb2d2305111
Translation updater bot [Thu, 12 May 2016 19:52:56 +0000 (21:52 +0200)]
Localisation updates from https://translatewiki.net.
Change-Id: I96105a757969f20b5ae7449773862dc92fa542cc
jenkins-bot [Thu, 12 May 2016 19:44:17 +0000 (19:44 +0000)]
Merge "Document WAN cache FLD_* constants"
jenkins-bot [Thu, 12 May 2016 19:30:12 +0000 (19:30 +0000)]
Merge "objectcache: Inject current time into WANObjectCache::wrap()"
jenkins-bot [Thu, 12 May 2016 19:24:32 +0000 (19:24 +0000)]
Merge "Add tests for Title::getPrefixedText()"
jenkins-bot [Thu, 12 May 2016 19:22:27 +0000 (19:22 +0000)]
Merge "registration: Handle $wgSessionProviders in ExtensionProcessor"
jenkins-bot [Thu, 12 May 2016 19:20:34 +0000 (19:20 +0000)]
Merge "Add wfDeprecated calls to WatchedItem"
jenkins-bot [Thu, 12 May 2016 19:10:31 +0000 (19:10 +0000)]
Merge "Re add @access protected on Title::__construct"
jenkins-bot [Thu, 12 May 2016 19:10:25 +0000 (19:10 +0000)]
Merge "wfTempDir try harder to get a tmp dir on Windows"
Gergő Tisza [Wed, 11 May 2016 21:41:42 +0000 (21:41 +0000)]
registration: Handle $wgSessionProviders in ExtensionProcessor
See https://www.mediawiki.org/wiki/Manual:$wgSessionProviders
Change-Id: Ic9daf9898a0c044d1e2611ca0276d7904a3372ce
Aaron Schulz [Thu, 12 May 2016 04:48:04 +0000 (21:48 -0700)]
objectcache: Inject current time into WANObjectCache::wrap()
Change-Id: Iaba8e09b904e12c0f6883cf6f10211e82a7d75db
Kunal Mehta [Thu, 12 May 2016 18:35:20 +0000 (11:35 -0700)]
Parser tests: Also register namespace 101 to accompany 100
It is expected that namespaces (except for NS_SPECIAL) will have a
paired subject and talk namespace. While not having the accompanying
talk namespace mostly works, it can cause unexpected issues when some
code paths (e.g. WikiPage::onArticleCreate()) expect it to exist.
Change-Id: I8f02fd886d0256679dfc10e1743204da4c6678b7
Kunal Mehta [Wed, 27 Apr 2016 21:52:50 +0000 (14:52 -0700)]
LinkCache: Use LinkTarget instead of Title
Change-Id: I9ed5a095fc50334a3c41fd52f6d05611dadbaf68
Kunal Mehta [Thu, 12 May 2016 18:25:51 +0000 (11:25 -0700)]
TitleFormatter: Match Title behavior for non-existent namespaces
In TitleFormatter::getPrefixedDBkey(), match the
Title::getPrefixedDBkey() behavior for non-existent namespaces by using
an empty string for the namespace and including a leading colon.
Change-Id: I195c36df69963c7409711dd97bece078f61faf77
Kunal Mehta [Thu, 12 May 2016 18:14:47 +0000 (11:14 -0700)]
Add tests for Title::getPrefixedText()
Change-Id: I2afd7ef8b6fd733dd2928a82e89b158fc6fab56d
jenkins-bot [Thu, 12 May 2016 11:47:08 +0000 (11:47 +0000)]
Merge "Make updateCollation wait for slaves every 500 (instead of 2000)"
jenkins-bot [Thu, 12 May 2016 11:38:49 +0000 (11:38 +0000)]
Merge "collation: Refactor getFirstLetterData() cache handling"
jenkins-bot [Thu, 12 May 2016 11:25:46 +0000 (11:25 +0000)]
Merge "resourceloader: Remove false return from Context::getUserObj()"
Brian Wolff [Thu, 12 May 2016 10:32:47 +0000 (06:32 -0400)]
Make updateCollation wait for slaves every 500 (instead of 2000)
2000 writes per wfWaitForSlaves() seems a bit high. There was a
report of this script causing some slave lag when being run.
Note that, the amount of time between wfWaitForSlaves() was
previously increased in r97146.
Bug: T58041
Change-Id: I07a29499775a17255865f25e6b9f1058f898193b
jenkins-bot [Thu, 12 May 2016 08:39:10 +0000 (08:39 +0000)]
Merge "Add LinkTarget::inNamespace() helper function"
jenkins-bot [Thu, 12 May 2016 08:31:22 +0000 (08:31 +0000)]
Merge "Add tests for 'LinkBegin' hook"
Kunal Mehta [Wed, 11 May 2016 21:01:48 +0000 (14:01 -0700)]
Add LinkTarget::inNamespace() helper function
And implementation for TitleValue, plus tests
Change-Id: I42c301e28938dcd55580e20b7c1ddefcbf5a2bef
jenkins-bot [Thu, 12 May 2016 04:21:18 +0000 (04:21 +0000)]
Merge "RedisBagOStuff: Fix unserialization of negative numbers"
Brad Jorsch [Thu, 12 May 2016 03:49:21 +0000 (20:49 -0700)]
RedisBagOStuff: Fix unserialization of negative numbers
ctype_digit( $data ) doesn't return true if $data is
a negative integer.
Bug: T134923
Change-Id: Ie8a23fc6354a15210e010062e3da3058f4c463bb
Aaron Schulz [Thu, 12 May 2016 03:25:14 +0000 (20:25 -0700)]
Document WAN cache FLD_* constants
Change-Id: Ie6a19ae2c5ab6f60a3c6818eb1c9016402bc86c9
Cblair91 [Sat, 30 Apr 2016 10:32:25 +0000 (10:32 +0000)]
Better JavaScript handling for return method
The length selector can be reduced to just find the child of $tbody, as it will check to see if both $tbody and the child .collapsible exist.
Change-Id: If927a5ca79d12f4654a1af9bad97c9274cb501e9
Kunal Mehta [Wed, 11 May 2016 22:50:29 +0000 (15:50 -0700)]
Add tests for 'LinkBegin' hook
Change-Id: I663c25377fb899ea97ef959efac82dc836a9940a
jenkins-bot [Wed, 11 May 2016 21:49:21 +0000 (21:49 +0000)]
Merge "mw.widgets.CategoryCapsuleItemWidget: Handle non-English foreign wikis"
Translation updater bot [Wed, 11 May 2016 19:53:14 +0000 (21:53 +0200)]
Localisation updates from https://translatewiki.net.
Change-Id: I7c6a49b3cc4f8a87eee1fa48bfd0b44c69f457c7
jenkins-bot [Wed, 11 May 2016 19:31:48 +0000 (19:31 +0000)]
Merge "Fix ApiBase::getErrorFromStatus() and ApiMessages"
Brad Jorsch [Wed, 11 May 2016 18:21:08 +0000 (14:21 -0400)]
Fix ApiBase::getErrorFromStatus() and ApiMessages
When the code was written, $status->getErrorsArray() would return the
Message objects unchanged. But I0deaa988 broke that and apparently
didn't bother fixing callers.
Now that I'm trying to actually use it for something, I find it's
broken, so I fixed it.
Change-Id: I763729c5bdd63448b50229774ef1f9d12cfb795d
Kunal Mehta [Wed, 27 Apr 2016 23:18:15 +0000 (16:18 -0700)]
Add TitleFormatter::getPrefixedDBkey() and implementation
Matches the expected result of Title::getPrefixedDBkey(), and will be
used in LinkCache.
Change-Id: I5ca65d07e2ae28778d060208e2bfe3fc0529992a
jenkins-bot [Wed, 11 May 2016 17:47:09 +0000 (17:47 +0000)]
Merge "Add tests for 'LinkEnd' hook functionality"
jenkins-bot [Wed, 11 May 2016 17:47:04 +0000 (17:47 +0000)]
Merge "Add TitleParser and TitleFormatter to MediaWikiServices"
Kunal Mehta [Wed, 11 May 2016 04:39:22 +0000 (21:39 -0700)]
Add tests for 'LinkEnd' hook functionality
Change-Id: I5bd353756c0631b3dd1c214f814040d82d7c361f
Kunal Mehta [Mon, 25 Apr 2016 05:41:32 +0000 (22:41 -0700)]
Add TitleParser and TitleFormatter to MediaWikiServices
Depends-On: Ibfd0a7f98f50506cd8402f966682f320bf715c8a
Change-Id: I81d48616afd1ab2bde1a5f1d12f4aefb1c866d43
jenkins-bot [Wed, 11 May 2016 17:06:05 +0000 (17:06 +0000)]
Merge "use slave for row estimate in updateCollation.php"
jenkins-bot [Wed, 11 May 2016 17:04:27 +0000 (17:04 +0000)]
Merge "Use STRAIGHT_JOIN on updateCollation.php per jcrespo"
jenkins-bot [Wed, 11 May 2016 15:21:23 +0000 (15:21 +0000)]
Merge "resourceloader: Remove unused Module::setOrigin() method"
jenkins-bot [Wed, 11 May 2016 15:16:48 +0000 (15:16 +0000)]
Merge "Add SessionInfo force-use flag"
jenkins-bot [Wed, 11 May 2016 14:03:34 +0000 (14:03 +0000)]
Merge "Add SessionManager::invalidateSessionsForUser"
jenkins-bot [Wed, 11 May 2016 11:42:41 +0000 (11:42 +0000)]
Merge "Add WebRequest methods for determining "safe" requests"
jenkins-bot [Wed, 11 May 2016 04:37:22 +0000 (04:37 +0000)]
Merge "Pass the OutputPage object to the OutputPageCheckLastModified hook"
Roan Kattouw [Wed, 11 May 2016 00:13:47 +0000 (17:13 -0700)]
Pass the OutputPage object to the OutputPageCheckLastModified hook
So that the hook function has a ContextSource.
Change-Id: I044a5920b703a2d61a74c2d83d184b77caebb8f3
jenkins-bot [Wed, 11 May 2016 00:59:53 +0000 (00:59 +0000)]
Merge "Add User::isBot() method"
Aaron Schulz [Sun, 8 May 2016 09:11:14 +0000 (02:11 -0700)]
Add User::isBot() method
Global group and other extensions can hook into the hook
to flag global bots and the like.
Change-Id: I1290932fccb62508d2a8b7f94f056badadf6fdfc
jenkins-bot [Wed, 11 May 2016 00:25:42 +0000 (00:25 +0000)]
Merge "Make GenderCache use MediaWikiServices"
James D. Forrester [Tue, 10 May 2016 23:06:27 +0000 (16:06 -0700)]
Update OOjs UI to v0.17.2
Release notes:
https://phabricator.wikimedia.org/diffusion/GOJU/browse/master/History.md;v0.17.2
Change-Id: I8e8101e3284c69f8fa6edf142f4cf84efff65e09
jenkins-bot [Tue, 10 May 2016 22:29:43 +0000 (22:29 +0000)]
Merge "Update default hash storage settings"
Brad Jorsch [Tue, 10 May 2016 20:40:46 +0000 (16:40 -0400)]
Add SessionManager::invalidateSessionsForUser
Most of the time calling User::setToken() is enough, but CentralAuth
needs to be able to call CentralAuthUser::resetAuthToken() on command.
Change-Id: Iad2ae914a81481f040e047b550f3fd3437277626
jenkins-bot [Tue, 10 May 2016 20:09:02 +0000 (20:09 +0000)]
Merge "Convert Special:WhatLinksHere from XML form to OOUI form"
Translation updater bot [Tue, 10 May 2016 19:59:57 +0000 (19:59 +0000)]
Merge "Localisation updates from https://translatewiki.net."
Brad Jorsch [Tue, 10 May 2016 19:25:39 +0000 (15:25 -0400)]
Add SessionInfo force-use flag
A provider that uses SessionProvider::hashToSessionId() will likely have
issues if something such as a call to $user->setToken() causes
SessionManager::loadSessionInfoFromStore() to fail, since the provider
can't just arbitrarily change the session ID it returns.
The two solutions to this problem are:
* Somehow include everything that could cause loadSessionInfoFromStore
to fail in the data hashed by hashToSessionId.
* Flag the SessionInfo so that, if stored data and the SessionInfo
conflict, it should delete the stored data instead of discarding the
SessionInfo.
Since the second is less complexity overall due to the lack of need to
define "everything", this patch takes that approach.
Change-Id: I8c6fab2ec295e71242bbcb19d0ee5ade6bd655df
Ajayrahul P [Sat, 12 Mar 2016 13:43:04 +0000 (19:13 +0530)]
Convert Special:WhatLinksHere from XML form to OOUI form
Bug: T117754
Change-Id: I902269c4dbf4147d291c98e61dbdad1d99bd3732
jenkins-bot [Tue, 10 May 2016 19:58:28 +0000 (19:58 +0000)]
Merge "Convert Special:MergeHistory to use OOUI."
Translation updater bot [Tue, 10 May 2016 19:57:33 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.
Change-Id: Ic9f08416c57ebe67a3ebdac74c273f2b2a4abd4b
Sethakill [Sun, 8 May 2016 10:03:29 +0000 (12:03 +0200)]
Convert Special:MergeHistory to use OOUI.
Bug: T134675
Change-Id: I8234632daff04902f317b5d8c84207e30b845358
Timo Tijhof [Tue, 10 May 2016 19:37:46 +0000 (20:37 +0100)]
resourceloader: Remove false return from Context::getUserObj()
Most code paths already wrongly assume this behaviour.
This patch removes the now-redundant check from the two modules
that did account for it.
Change-Id: Ic85258f184db8aa68e19d8e667e396d08ee5de0c
Brian Wolff [Tue, 10 May 2016 19:38:27 +0000 (15:38 -0400)]
use slave for row estimate in updateCollation.php
jcrespo reported a lag spike at the very beginning of running this
script. I'm guessing that's due to counting how many rows in
categorylinks to give the progress bar. Since we only need a
rough estimate for the progress meter, make that query run on
a slave. Also add a wfWaitForSlaves() immediately after it for
good measure.
Bug: T58041
Change-Id: I3cba392f0013fcb2ef86803632e2d9b1b88b3b29
Brian Wolff [Tue, 10 May 2016 19:30:03 +0000 (15:30 -0400)]
Use STRAIGHT_JOIN on updateCollation.php per jcrespo
Was not using the right index on ruwiktionary
Bug: T58041
Change-Id: Ib55a2cdd7807a96df7076a1b54457dd4f74912ce
Aaron Schulz [Fri, 6 May 2016 22:25:36 +0000 (15:25 -0700)]
Add WebRequest methods for determining "safe" requests
* This is useful for logic that decides what DB (master/slave) to use
based on the nature of the web request. It could also be used to
enforce clear read/write distinctions via exceptions if DB_MASTER
is misused.
* Also fixed two IDEA errors while editing this class.
Bug: T134608
Change-Id: I43f4bc06c19d823d7d1ffd9cee8bbe60563c7f82
Timo Tijhof [Tue, 10 May 2016 18:13:29 +0000 (19:13 +0100)]
resourceloader: Remove unused Module::setOrigin() method
Follows-up
da36f65433d which added this method with intent to use in
ResourceLoader::register(). However, the feature was redesigned to
not need this and the method was left behind.
Change-Id: I5ebc93805d0df6605bec94094bcd4eb2b70ff18d
jenkins-bot [Tue, 10 May 2016 13:19:44 +0000 (13:19 +0000)]
Merge "Avoid master queries on GET in ProtectionForm"
jenkins-bot [Tue, 10 May 2016 13:06:14 +0000 (13:06 +0000)]
Merge "Remove DELETE_SOURCE flag from FileRepo store()/storeBatch()"
jenkins-bot [Tue, 10 May 2016 12:59:42 +0000 (12:59 +0000)]
Merge "Make recent changes update jobs use configurable $wgUpdateRowsPerQuery"