Gergő Tisza [Thu, 11 Jul 2019 10:18:08 +0000 (12:18 +0200)]
Release notes for deprecating User::getRights() and breaking User::$mRights
The actual change was in I88992403.
Change-Id: Ibecec431001a53db4502cf0377342c8aacc7bebe
Aaron Schulz [Sat, 6 Jul 2019 04:35:04 +0000 (21:35 -0700)]
jobqueue: fix IDEA warnings in JobQueueRedis
Change-Id: I7258191cbae22028d76a52c005f44b7347bd86aa
jenkins-bot [Thu, 11 Jul 2019 06:19:24 +0000 (06:19 +0000)]
Merge "Various fixes and simplifications to RefreshLinksJob::runTitle()"
Max Semenik [Thu, 11 Jul 2019 06:14:45 +0000 (23:14 -0700)]
mediawiki.dic: Remove Zero-related stuff
Change-Id: I5f0d8314f754d0331fe06af551b3f65df192752a
Aaron Schulz [Tue, 2 Apr 2019 08:25:48 +0000 (01:25 -0700)]
Various fixes and simplifications to RefreshLinksJob::runTitle()
* Remove logic for saving slow-to-render parser output. This has
not worked ever since DerivedPageDataUpdater was introduced.
* Make the logic to use cached output actually work. This was
also broken since DerivedPageDataUpdater was added. In order
to pass the output, add a known-revision-output parameter
to both WikiPage::doSecondaryUpdates() and
DerivedPageDataUpdater::prepareUpdate().
* Also factored out some helper methods from runForTitle() in
RefreshLinksJob to make it more readable and avoid the need
for multiple transaction round commit calls. This makes the
case of multiple-title jobs less likely to break again.
* Make use of RefreshLinksJob::runForTitle() return value.
* Add unit tests for multiple-title job case.
Change-Id: I0cd13c424a87653b5a7253c42cd48fe43befd692
Tim Starling [Thu, 11 Jul 2019 05:59:56 +0000 (15:59 +1000)]
Some fixes to page updater docs
A couple of typos, and also remove a thing that says isDeleted() should
be skipped for the current revision -- isDeleted() does not do a DB
query so there's no performance rationale for spreading assumptions and
increasing complexity in that way.
Change-Id: I661a6889618f188a9aa72f2f9a2c2ebf69ba09c4
jenkins-bot [Thu, 11 Jul 2019 04:00:22 +0000 (04:00 +0000)]
Merge "Allow PHP version check to execute on older versions of PHP"
jenkins-bot [Thu, 11 Jul 2019 03:56:07 +0000 (03:56 +0000)]
Merge "Html: Make linkButton() documentation less confusing"
Bill Pirkle [Thu, 11 Jul 2019 02:16:49 +0000 (21:16 -0500)]
Allow PHP version check to execute on older versions of PHP
A change to update.php used the null coalesce (??) operator.
While this is normally fine, the code in question executes
before the PHP version check, and causes an unfriendly PHP
error rather than the intended helpful error. Use the older-style
isset() call instead, so that the PHP version check will get
a chance to execute.
Bug: T213893
Change-Id: I22e4a24bed9e0b29e08afc7b9468e7bfd81d7d57
jenkins-bot [Thu, 11 Jul 2019 02:10:20 +0000 (02:10 +0000)]
Merge "Normalize the code style of some ResultWrapper iteration loops"
jenkins-bot [Thu, 11 Jul 2019 02:10:14 +0000 (02:10 +0000)]
Merge "Update $wgMainStash comments and merge in those from a deprecated ObjectCache method"
Aaron Schulz [Thu, 11 Jul 2019 01:21:51 +0000 (18:21 -0700)]
rdbms: avoid dbSchema() in Database::replaceLostConnection() and Database::__clone()
Since dbSchema() always casts the result to a string, using this method
with a call to open() is broken if the RDBMs does not support DB schemas
and thus requires null
Follows-up
7911da9c6f (last week), which added the check in
DatabaseMysqlBase::open() check. Also follows
fe0af6cad (last year),
which made dbSchema() consistently return string. Before that, an
implicit null was passed in from Database::factory for mysql, which hid
the class default of empty string.
Bug: T227708
Change-Id: I67207fbaa39c5cc3fe062077cc654f048090e009
jenkins-bot [Wed, 10 Jul 2019 23:17:24 +0000 (23:17 +0000)]
Merge "objectcache: remove inheritence from CachedBagOStuff"
jenkins-bot [Wed, 10 Jul 2019 23:16:23 +0000 (23:16 +0000)]
Merge "objectcache: use OPT_TCP_NODELAY for MemcachedPeclBagOStuff"
Roan Kattouw [Wed, 10 Jul 2019 23:02:23 +0000 (16:02 -0700)]
Html: Make linkButton() documentation less confusing
The documentation for the first parameter said it was both "raw HTML"
and "not escaped", but those phrases have opposite meanings. Clarify that
this parameter takes plain text that will be escaped (so not raw HTML),
and rename the parameter from $contents (typically used to mean HTML) to
$text.
Change-Id: I44d6de08a68c493935b2ceff58fac6c51bc45d12
Aaron Schulz [Wed, 10 Jul 2019 03:03:14 +0000 (20:03 -0700)]
Make MapCacheLRU::get() accept a default value and improve $maxAge default
Change-Id: If562e1745ffed37b0f1ed5382a5a397fc68aac8e
Amir Sarabadani [Tue, 9 Jul 2019 10:51:49 +0000 (12:51 +0200)]
Stop using wfDebugLog in LocalisationCache
Using logger interface, this would fix some unit tests, plus it
avoids using global functions and ease the way for proper dependency
injection
Change-Id: I9a545c70ace08e2fd0b832d75d6a2362a83af21e
Aaron Schulz [Wed, 10 Jul 2019 22:06:05 +0000 (15:06 -0700)]
Normalize the code style of some ResultWrapper iteration loops
Change-Id: Iced52ae65d31d1ca0cd2c64ebc9ab56b2aef9617
Aaron Schulz [Wed, 10 Jul 2019 22:18:48 +0000 (15:18 -0700)]
Add NS_MEDIAWIKI to LinkCache::isCacheable() to help MessageBlobStore cache regeneration
Change-Id: I55550a0ea5b9db0c87a67bb8bc06e846db58b9fe
Aaron Schulz [Sat, 29 Jun 2019 19:12:03 +0000 (12:12 -0700)]
objectcache: use OPT_TCP_NODELAY for MemcachedPeclBagOStuff
Clean up the option setting code in __construct() as well
and make it more strict in terms of checking bogus options
Make mctest.php recognize when memcached is used more easily
Change-Id: I77be506e80478ddbb4fcfa44d82aba8162fa984f
jenkins-bot [Wed, 10 Jul 2019 21:49:59 +0000 (21:49 +0000)]
Merge "Allow false as return type of FileBackendStore::doGetFileXAttributes"
Aaron Schulz [Wed, 10 Jul 2019 21:32:08 +0000 (14:32 -0700)]
objectcache: remove inheritence from CachedBagOStuff
Change-Id: I24e5b6a95d74730c1679bdc7b7b394adcb6bd794
jenkins-bot [Wed, 10 Jul 2019 21:23:53 +0000 (21:23 +0000)]
Merge "build: Updating mediawiki/mediawiki-phan-config to 0.6.1"
Aaron Schulz [Wed, 10 Jul 2019 21:02:41 +0000 (14:02 -0700)]
Update $wgMainStash comments and merge in those from a deprecated ObjectCache method
Change-Id: I807f36d9c51476a969d7046d57bfc32cf37c2745
jenkins-bot [Wed, 10 Jul 2019 20:58:00 +0000 (20:58 +0000)]
Merge "PHPUnit bootstrap: less aggressive unsetting of globals"
jenkins-bot [Wed, 10 Jul 2019 20:53:02 +0000 (20:53 +0000)]
Merge "User: support setting custom fields + array autocreation in non-existent field"
Gergő Tisza [Wed, 10 Jul 2019 18:46:21 +0000 (20:46 +0200)]
User: support setting custom fields + array autocreation in non-existent field
I889924037 added a __set method which did not actually handle fields being set.
For better or worse, setting custom fields on ubiquitous objects like User is a
common form of in-process caching, so this is a B/C break; restore for now.
PHP allows creating an array in a previously non-existent object property
with $o->foo['bar'] = $val, but doesn't properly handle that on objects
which have magic getter/setter. Add an ugly hack to make it work (but warn).
Depends on I15090ae9e4b66ac25f631f6179c4394ce8c445a9.
Bug: T227688
Change-Id: I62b80ab4fa10de984cf2c879ab12d91b0fd9bc1c
Roan Kattouw [Wed, 10 Jul 2019 20:15:20 +0000 (13:15 -0700)]
WatchedItemStore: Fix fatal when revision is deleted
People following links from their watchlist emails to since-deleted
revisions were getting fatals from
WatchedItemStore::getNotificationTimestamp().
It's hard to tell whether returning null or false is the right thing to
do here, because this function can return both and the difference is not
documented, and I wasn't able to find any callers that care about the
distinction.
Bug: T226741
Change-Id: Ib2a836099343f4c161227266dbeeafbc76dccc2b
jenkins-bot [Wed, 10 Jul 2019 19:58:37 +0000 (19:58 +0000)]
Merge "Localisation updates from https://translatewiki.net."
Translation updater bot [Wed, 10 Jul 2019 19:57:53 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.
Change-Id: I1a847d840c4263f055261c78fc9b487fc0537ffe
Aaron Schulz [Wed, 10 Jul 2019 06:51:43 +0000 (23:51 -0700)]
objectcache: rename "slaveOnly" parameter to "replicaOnly" in SQLBagOStuff
Also removed redundant check
Change-Id: I9f454eb15f223f5a9816dca4510c1a9add540b49
jenkins-bot [Wed, 10 Jul 2019 19:10:25 +0000 (19:10 +0000)]
Merge "Tests: Assert that integration tests are not in unit test directory"
jenkins-bot [Wed, 10 Jul 2019 18:02:43 +0000 (18:02 +0000)]
Merge "Pass in ServiceOptions to BlockManager"
jenkins-bot [Wed, 10 Jul 2019 18:02:36 +0000 (18:02 +0000)]
Merge "Tidy up conditions for applying a block from a cookie"
Kosta Harlan [Wed, 10 Jul 2019 17:20:00 +0000 (13:20 -0400)]
PHPUnit bootstrap: less aggressive unsetting of globals
Previous approach caused breakage with "Notice: Undefined index: _SERVER"
messages, see e.g.
https://gerrit.wikimedia.org/r/c/mediawiki/core/+/521268#message-
4502e6c209f53f6dc1c7cdf4f60e5045bbfb6ee4
Change-Id: Ief20e4e21fd99d219ebef865c603e336c2609ce2
Follows-Up: I16691fc8ac063705ba0c2bc63b96c4534ca8660b
Bug: T87781
Kosta Harlan [Wed, 10 Jul 2019 17:41:44 +0000 (13:41 -0400)]
Tests: Assert that integration tests are not in unit test directory
Bug: T87781
Change-Id: If82efb1829095a6cf76435921f1328801508a70a
Brad Jorsch [Wed, 10 Jul 2019 17:30:03 +0000 (13:30 -0400)]
Linker: Fix incorrect test added in Ib9816d8b
The test was intended to check for whether we have a user ID *or* a user
name. Instead, it's checking if we have a user ID *and* a user name. And
it also failed to consider User:0.
Bug: T227656
Change-Id: Ia1b5c4a6ae028513b73a65cd2c885459327d29c3
jenkins-bot [Wed, 10 Jul 2019 17:28:35 +0000 (17:28 +0000)]
Merge "Make RouterTest extend MediawikiUnitTestCase and not integration"
James D. Forrester [Mon, 10 Jun 2019 19:48:13 +0000 (12:48 -0700)]
build: Updating mediawiki/mediawiki-phan-config to 0.6.1
Change-Id: I370fed5248c8b243527cafb77d80ddb6f4bc7064
jenkins-bot [Wed, 10 Jul 2019 17:02:17 +0000 (17:02 +0000)]
Merge "Replace old URLs in SampleTest"
Amir Sarabadani [Wed, 10 Jul 2019 16:47:39 +0000 (18:47 +0200)]
Make RouterTest extend MediawikiUnitTestCase and not integration
it's in unit directory, it causes things to break
Change-Id: Ibeafafde5a3b9f3f8e6fda0ceef8575aa544e20b
jenkins-bot [Wed, 10 Jul 2019 16:34:47 +0000 (16:34 +0000)]
Merge "bagostuff: optimize SqlBagOStuff and fix failing segmentation tests"
jenkins-bot [Wed, 10 Jul 2019 16:12:54 +0000 (16:12 +0000)]
Merge "rdbms: make IDatabase::isReadOnly() return true for replica DBs managed by LoadBalancer"
Thalia [Wed, 26 Jun 2019 14:06:01 +0000 (15:06 +0100)]
Pass in ServiceOptions to BlockManager
Change-Id: Ic63d7ff35a71e36c4e6157e9d472e2870f95f00d
Thalia [Wed, 26 Jun 2019 10:04:50 +0000 (11:04 +0100)]
Tidy up conditions for applying a block from a cookie
Change-Id: Id9dd6ae395f5bb811db4c741be9db8aa2eb6fb70
jenkins-bot [Wed, 10 Jul 2019 15:28:25 +0000 (15:28 +0000)]
Merge "Update OOUI to v0.33.2"
jenkins-bot [Wed, 10 Jul 2019 15:01:18 +0000 (15:01 +0000)]
Merge "Remove references to db field ar_text_id"
Volker E [Wed, 10 Jul 2019 14:07:23 +0000 (07:07 -0700)]
Update OOUI to v0.33.2
Release notes:
https://phabricator.wikimedia.org/diffusion/GOJU/browse/master/History.md;v0.33.2
Bug: T158708
Bug: T226780
Bug: T227040
Bug: T227275
Depends-on: I3d7a990d0f32734a9048ec55d22035150a562f04
Change-Id: I4287a6f2e950a8ad0511b24f4a1c8074e4f427b3
jenkins-bot [Wed, 10 Jul 2019 14:09:26 +0000 (14:09 +0000)]
Merge "Isolate globals for ContentSecurityPolicy tests"
Thalia [Mon, 27 May 2019 12:35:18 +0000 (13:35 +0100)]
Replace old URLs in SampleTest
Update URLs to point to documentation for version 6.5, and fix a
couple of broken URLs.
Change-Id: I25211d4da19a40837d7fb7fc6219486f1a7a7c0e
jenkins-bot [Wed, 10 Jul 2019 10:41:11 +0000 (10:41 +0000)]
Merge "REST: add write access checks to BasicAccess"
jenkins-bot [Wed, 10 Jul 2019 10:26:33 +0000 (10:26 +0000)]
Merge "Add rest.php (REST API endpoint) with feature flag"
jenkins-bot [Wed, 10 Jul 2019 10:26:26 +0000 (10:26 +0000)]
Merge "REST: basic read restrictions"
Aaron Schulz [Wed, 10 Jul 2019 06:51:24 +0000 (23:51 -0700)]
rdbms: make IDatabase::isReadOnly() return true for replica DBs managed by LoadBalancer
Change-Id: I25b70fe0ea113c6741601cf0366a0fe9dc5cc3ef
jenkins-bot [Wed, 10 Jul 2019 06:42:16 +0000 (06:42 +0000)]
Merge "maintenance: Script to rename titles for Unicode uppercasing changes"
Aaron Schulz [Sat, 29 Jun 2019 17:26:37 +0000 (10:26 -0700)]
bagostuff: optimize SqlBagOStuff and fix failing segmentation tests
In SqlBagOStuff:
* Add modifyMulti() helper method to reduce code duplication
* Improve atomicity of add(), cas(), and changeTTL() queries
* Avoid integer serialization and improve atomicity of incr()
* Optimize new BagOStuff::changeTTLMulti() method
In BagOStuff:
* Add changeTTLMulti() method for subclasses to optimize
* Make set() ignore WRITE_ALLOW_SEGMENTS for integers so incr() works
* Strip WRITE_ALLOW_SEGMENTS flag from the setMulti() call in set() to
avoid triggering bogus sanity check exceptions
* Fix BagOStuffTest::testSetSegmentable failures via the above changes
* Enforce WRITE_ALLOW_SEGMENTS sanity check in setMulti() for all the
subclasses by using a final wrapper method
* Add WRITE_ALLOW_SEGMENTS sanity check to deleteMulti()
Bug: T113916
Change-Id: I25d1790fa9b0d1837643efccfa94a12043cfbf42
jenkins-bot [Wed, 10 Jul 2019 02:38:59 +0000 (02:38 +0000)]
Merge "Fix typo in table documentation"
jenkins-bot [Wed, 10 Jul 2019 01:40:38 +0000 (01:40 +0000)]
Merge "Add safemode to special redirect parameters that are preserved"
jenkins-bot [Tue, 9 Jul 2019 22:14:49 +0000 (22:14 +0000)]
Merge "config: Change ConfigException to extend LogicException"
Aaron Schulz [Sat, 6 Jul 2019 03:29:39 +0000 (20:29 -0700)]
rdbms: rename LoadMonitor "parent" field to "lb"
Change-Id: I21246ca1ba00280839216b378899f2fcae266857
Bill Pirkle [Wed, 24 Apr 2019 21:46:12 +0000 (16:46 -0500)]
Remove references to db field ar_text_id
Field ar_text_id is being removed as part of MCR schema changes.
Remove references to this field. These references were already
unnecessary due to commit
07842be3.
Bug: T198341
Change-Id: I3dbf12abf3f67fa0ea07c535e830c9d40b46fdc3
jenkins-bot [Tue, 9 Jul 2019 20:36:37 +0000 (20:36 +0000)]
Merge "Move unit tests, round III"
Amir Sarabadani [Sun, 7 Jul 2019 23:28:25 +0000 (01:28 +0200)]
Move unit tests, round III
Depends-On: I16691fc8ac063705ba0c2bc63b96c4534ca8660b
Bug: T87781
Change-Id: I5e1ab06e3decef6cc6090551d54dc4314ab9314a
Translation updater bot [Tue, 9 Jul 2019 19:57:36 +0000 (21:57 +0200)]
Localisation updates from https://translatewiki.net.
Change-Id: If1fe24c743ae95416ff816989ec15d4042612604
jenkins-bot [Tue, 9 Jul 2019 19:52:07 +0000 (19:52 +0000)]
Merge "Add fields and docs to WikiExporter"
jenkins-bot [Tue, 9 Jul 2019 19:48:58 +0000 (19:48 +0000)]
Merge "rdbms: avoid recursion in LoadBalancer when the master has non-zero load"
jenkins-bot [Tue, 9 Jul 2019 19:36:07 +0000 (19:36 +0000)]
Merge "jobqueue: mention more methods in RunnableJob to fix various IDEA warnings"
Aaron Schulz [Thu, 27 Jun 2019 18:52:04 +0000 (11:52 -0700)]
rdbms: avoid recursion in LoadBalancer when the master has non-zero load
Add and use IDatabase::getServerConnection() method to avoid loops caused
caused by pickReaderIndex() calling getConnection() for the master server.
That lead to getReadOnlyReason() triggering pickReaderIndex() again.
Make getLaggedReplicaMode() apply when the master has non-zero load and
the replicas are all lagged.
Remove "allReplicasDownMode" in favor of checking getExistingReaderIndex()
instead. This reduces the amount of state to keep track of a bit.
Follow-up to
95e2c990940f
Bug: T226678
Bug: T226770
Change-Id: Id932c3fcc00625e3960f76d054d38d9679d25ecc
jenkins-bot [Tue, 9 Jul 2019 18:57:55 +0000 (18:57 +0000)]
Merge "Unset all globals unneeded for unit tests, assert correct directory"
Amir Sarabadani [Mon, 8 Jul 2019 13:25:31 +0000 (15:25 +0200)]
Unset all globals unneeded for unit tests, assert correct directory
* Unset globals to avoid tests that look like unit tests but actually rely on
globals
* move some tests out of unit directory so that the test suite will pass.
* Assert that tests which extend MediaWikiUnitTestCase are in a directory with
"/unit/" in its path name
Depends-On: I67b37b1bde94eaa3d4298d9bd98ac57995ce93b9
Depends-On: I90921679518ee95fe393f8b1bbd9134daf0ba032
Bug: T87781
Change-Id: I16691fc8ac063705ba0c2bc63b96c4534ca8660b
jenkins-bot [Tue, 9 Jul 2019 18:00:06 +0000 (18:00 +0000)]
Merge "objectcache: simplify WANObjectCache version handling code"
Brad Jorsch [Tue, 30 Apr 2019 15:33:06 +0000 (11:33 -0400)]
maintenance: Script to rename titles for Unicode uppercasing changes
This uses MovePage where possible to try to better keep data in sync.
Archives, log entries, and so on can't do that though.
The script skips User and User_talk pages for registered users, as
renaming the users is more complicated than makes sense to try to
implement here. Use something like Extension:Renameuser to clean those
up; this script can provide a list of user names affected.
Bug: T219279
Change-Id: I157577cb5bedfd347b808c254fb19ae8088818ab
jenkins-bot [Tue, 9 Jul 2019 17:47:24 +0000 (17:47 +0000)]
Merge "jobqueue: remove unused "aggregator" field reference in JobQueueFederated"
jenkins-bot [Tue, 9 Jul 2019 17:47:17 +0000 (17:47 +0000)]
Merge "objectcache: deleteObjectsExpiringBefore() signature and code improvements"
jenkins-bot [Tue, 9 Jul 2019 17:34:22 +0000 (17:34 +0000)]
Merge "Run SpecialPageFatalTest with lang=qqx"
Thalia [Tue, 9 Jul 2019 17:31:21 +0000 (18:31 +0100)]
Fix typo in table documentation
Change-Id: Ifa9839567797921ca81938e5c77a1a53a42eef94
jenkins-bot [Tue, 9 Jul 2019 17:22:23 +0000 (17:22 +0000)]
Merge "Correct typo `notMinimumVerisonMessage'"
jenkins-bot [Tue, 9 Jul 2019 16:11:09 +0000 (16:11 +0000)]
Merge "Recognizes Open Document Database"
Kosta Harlan [Wed, 3 Jul 2019 14:48:55 +0000 (10:48 -0400)]
Speed up code coverage generation for local development
Changing addUncoveredFilesFromWhitelist to false drastically speeds up code
coverage report generation. Including extensions/skins in the config also
removes the need to manually edit your phpunit.xml file when you want to inspect
code coverage for your extension or skin locally.
With this patch you can very quickly generate coverage for an extension/skin or
subsection of core, this is especially useful if you are using an IDE that
supports running a test and importing its coverage into the editor.
The downside to this patch is that the coverage report only contains
information about code that's exercised by the tests, so this patch on its own
is unsuitable for our current processes in integration/config which generate a
full code coverage report per patch for extensions or post-merge for core.
However, since we are not yet using phpunit.xml.dist in CI, this patch should be
OK to merge as is. A follow-up patch to integration/config will use sed or
phpunit-suite-edit.py to set processUncoveredFilesFromWhitelist to true.
Bug: T192078
Change-Id: I3d19627fa36f6cc6666c29fdb638272fdaa30630
jenkins-bot [Tue, 9 Jul 2019 15:11:57 +0000 (15:11 +0000)]
Merge "Improve type hints in parser related classes"
Antoine Musso [Mon, 31 Dec 2018 17:30:00 +0000 (18:30 +0100)]
Recognizes Open Document Database
Mediawiki does not recognizes the mime type of an OpenOffice / Libre
Office Database Frontend Document and thus uses application/zip.
Our MimeAnalyzer::detectZipType() looks at the Zip files to detect known
signatures, however it is based on a reference from 2005 which did not
have the Database type yet.
OASIS Open Document Format v1.2 specify non normative MIME types, the
reference supposedly being the ones registered with the IANA, but we
have some dispredancy: ODF recommends 'base' while the IANA got
'database' registered: https://www.iana.org/assignments/media-types/
I supposed the format got approved as is, the Database mime type being
'recommended' probably because the IANA registration was pending.
Add the 'base' type which is being used by OpenOffice 3.x and later as
well as at least Libre Office 5.x.
Document my findings in code comments.
Add a test.
Bug: T35515
Change-Id: If0210a87067358612ecb8b3edd001fb05d01653d
Matěj Suchánek [Tue, 9 Jul 2019 11:07:07 +0000 (13:07 +0200)]
Don't show tools on history view when no revisions can be shown
Change-Id: I31c1d22a444928bf73d7ae0c0904cd1fb93865f4
Matěj Suchánek [Tue, 9 Jul 2019 10:36:41 +0000 (12:36 +0200)]
Correctly distinguish the latest revision in action=history
The latest revision is the last revision made to a page.
It isn't necessarily the first revision shown in a history
view because of the filters above.
Bug: T194203
Change-Id: I4b232482e682e090235dbbd0732ff61fbad3ccda
Aaron Schulz [Tue, 9 Jul 2019 06:02:05 +0000 (23:02 -0700)]
objectcache: deleteObjectsExpiringBefore() signature and code improvements
Make the method use a callable type hint for $progressCallback.
Also make the SQLBagOStuff subclass shuffle() the array of server and table
indexes in case the limit keeps getting applied. Only garbage collect on DBs
that were going to be written to anyway. Also use DeferredUpdates if possible.
Change-Id: I723e6377c26750ff98e33f7ab103c6162ae65f43
Derick Alangi [Wed, 3 Jul 2019 12:17:16 +0000 (13:17 +0100)]
objectcache: Hard deprecate `ObjectCache::getMainWANInstance()`
This method was soft-deprecated in 1.28 and this patch cleans up
usage (via object cache) in core and uses services. So, this is now
fit for hard deprecation.
Usage
=====
https://codesearch.wmflabs.org/search/?q=getMainWANInstance&i=nope&files=&repos=
Change-Id: I081a979ed6ed7acf37168a6d81ca4048aae5dd9c
Daimona Eaytoy [Tue, 9 Jul 2019 08:33:03 +0000 (10:33 +0200)]
Add fields and docs to WikiExporter
Three fields were undeclared, thus raising some phan warnings.
Change-Id: Ib7934b507cb69d29a3d2422dadc24b12207a12ad
Aaron Schulz [Tue, 9 Jul 2019 05:56:25 +0000 (22:56 -0700)]
jobqueue: remove unused "aggregator" field reference in JobQueueFederated
Change-Id: I355d1669a3845508d9be3ad11653f1b98446d9be
Tim Starling [Tue, 9 Jul 2019 02:39:06 +0000 (12:39 +1000)]
REST: add write access checks to BasicAccess
This is a stub implementation which just checks for the apiwrite
permission.
Change-Id: Ib84cd93e7f0f5e31cf620b2d30609035c4448c95
Tim Starling [Thu, 16 May 2019 04:36:45 +0000 (14:36 +1000)]
Add rest.php (REST API endpoint) with feature flag
Change-Id: I0f9aaa9cc81f93c00f7a28041615d7290b453803
Tim Starling [Wed, 26 Jun 2019 02:33:35 +0000 (12:33 +1000)]
REST: basic read restrictions
Protect private wikis by providing basic read restrictions,
closely following the example of the action API.
The BasicAccess module provides a narrow interface for this
functionality, without exposing the whole session/user concept to the
router.
Also, add RouterTest and fix a bug in Router::getRelativePath() thus
discovered.
Change-Id: I82319d56f08b2eec4a585ff6dbd348ccdbadc5b5
Aaron Schulz [Tue, 9 Jul 2019 01:17:04 +0000 (18:17 -0700)]
objectcache: simplify WANObjectCache version handling code
Make getWithSetCallback() check for unversioned values instead
of doing it in multiple isValid() checks.
Also rename some variables in doGetWithSetCallback() for clarity.
Change-Id: I27fe0b2351643009d090964b9b57fa82ba658235
jenkins-bot [Mon, 8 Jul 2019 23:53:10 +0000 (23:53 +0000)]
Merge "installer: Avoid <doclink/> hack for 'config-sidebar' rendering"
jenkins-bot [Mon, 8 Jul 2019 23:51:45 +0000 (23:51 +0000)]
Merge "installer: Convert <downloadlink/> hack to raw message param"
jenkins-bot [Mon, 8 Jul 2019 23:51:38 +0000 (23:51 +0000)]
Merge "installer: Call getInfoBox() with raw wikitext, not transformed text"
jenkins-bot [Mon, 8 Jul 2019 23:49:14 +0000 (23:49 +0000)]
Merge "installer: Fix Html::infoBox param docs and mark as internal"
jenkins-bot [Mon, 8 Jul 2019 23:47:49 +0000 (23:47 +0000)]
Merge "build: Remove reference of non-existent "Fuzz" and "Stub" PHPUnit groups"
jenkins-bot [Mon, 8 Jul 2019 23:44:40 +0000 (23:44 +0000)]
Merge "build: Remove redundant 'vendor/bin' prefix from composer commands"
jenkins-bot [Mon, 8 Jul 2019 23:21:26 +0000 (23:21 +0000)]
Merge "mediawiki.util: Simplify test-only setOptions methods"
jenkins-bot [Mon, 8 Jul 2019 23:07:09 +0000 (23:07 +0000)]
Merge "lockmanager: tweak FSLockManager permission handling in doSingleLock()"
jenkins-bot [Mon, 8 Jul 2019 23:07:02 +0000 (23:07 +0000)]
Merge "objectcache: tweak SqlBagOStuff purging to happen on write only"