Page MenuHomePhabricator

API data push/pull guidelines
Open, LowPublic

Description

Author: M8R-udfkkf

Description:
There is a lack of guidelines regarding the rate at the mediawiki API may be used.

Specifically for the enwiki and commons api (if it doesn't matter, please say so):

For bots:

Are simultaneous uploads permitted? E.g. uploading 3 20MB files simultaneously to the commons on a 1Gbit/s line. What is the max rate permitted?

Related:
https://en.wikipedia.org/wiki/Wikipedia:Vpt#Asynchronous_uploads.2Fapi_usage

Unofficial:
https://meta.wikimedia.org/wiki/Data_request_limitations


Version: 1.21.x
Severity: minor

Details

Reference
bz44584

Event Timeline

bzimport raised the priority of this task from to Low.Nov 22 2014, 1:28 AM
bzimport set Reference to bz44584.
bzimport added a subscriber: Unknown Object (MLST).

This doesn't seem to be related to the MediaWiki API so much as a request for documentation about the allowed use of the API on WMF wikis. You'd probably do better to ask on wikitech-l[1] than in bugzilla.

The closest thing to an official guideline that I am aware of is
http://wikitech.wikimedia.org/view/Robot_policy#Request_rate

In general, best practice seems to be to have one request outstanding at any time, and to use maxlag[2] to have your bot automatically stop when the servers are overloaded.

[1]: https://lists.wikimedia.org/mailman/listinfo/wikitech-l
[2]: https://www.mediawiki.org/wiki/Manual:Maxlag_parameter

See also [[mw:API:Etiquette#Request limit]]

And Notes to library developers on [[mw:API:Client code#API Access Libraries]]