Page MenuHomePhabricator

effectively lower Item ID rate limit for bad Item creation requests
Closed, ResolvedPublic5 Estimated Story Points

Description

Problem:
In T272032 we created a rate limit for assigning new Item IDs. There are still a considerable number of IDs being skipped (about 1% atm).

We want to effectively lower the rate limit for bad requests (requests that don't end up creating an Item), while still allowing creating at the same rate as it is possible right now (90/minute).

BDD
GIVEN a API user sending Item creation requests
WHEN a bad request is sent
THEN increase the counter for how much of the rate limit this account is currently using by more than for a successful request

Acceptance criteria:

  • for Wikidata we add 9 to the rate limit counter if Item creation fails when ID generation has happened
  • by default we add 0 to the rate limit counter if Item creation fails when ID generation has happened
  • this value is configurable per installation

Notes:

Event Timeline

Lydia_Pintscher renamed this task from lower Item ID rate limit to lower Item ID rate limit for bad Item creation requests.Jun 8 2021, 8:29 AM
Lydia_Pintscher updated the task description. (Show Details)
Lydia_Pintscher updated the task description. (Show Details)
Lydia_Pintscher renamed this task from lower Item ID rate limit for bad Item creation requests to effectively lower Item ID rate limit for bad Item creation requests.Jun 9 2021, 10:21 AM

Change 699266 had a related patch set uploaded (by Ladsgroup; author: Ladsgroup):

[mediawiki/extensions/Wikibase@master] [WIP] Hook incrementing 'wikibase-idgenerator' ratelimit in case of error

https://gerrit.wikimedia.org/r/699266

Change 699266 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@master] Hook incrementing 'wikibase-idgenerator' ratelimit in case of error

https://gerrit.wikimedia.org/r/699266

Change 701875 had a related patch set uploaded (by Ladsgroup; author: Ladsgroup):

[operations/mediawiki-config@master] Set idGeneratorInErrorPingLimiter to 9 for Wikidata

https://gerrit.wikimedia.org/r/701875

Change 701875 merged by jenkins-bot:

[operations/mediawiki-config@master] Set idGeneratorInErrorPingLimiter to 9 for Wikidata

https://gerrit.wikimedia.org/r/701875

Mentioned in SAL (#wikimedia-operations) [2021-06-28T08:51:44Z] <ladsgroup@deploy1002> Synchronized wmf-config/InitialiseSettings.php: Config: [[gerrit:701875|Set idGeneratorInErrorPingLimiter to 9 for Wikidata (T284538)]], Part I (duration: 00m 56s)

Mentioned in SAL (#wikimedia-operations) [2021-06-28T08:53:31Z] <ladsgroup@deploy1002> Synchronized wmf-config/Wikibase.php: Config: [[gerrit:701875|Set idGeneratorInErrorPingLimiter to 9 for Wikidata (T284538)]], Part II (duration: 00m 57s)

Addshore added a subscriber: Addshore.

Hard to verify but the code looks good

Change 745257 had a related patch set uploaded (by Rosalie Perside (WMDE); author: Ladsgroup):

[mediawiki/extensions/Wikibase@REL1_36] Hook incrementing 'wikibase-idgenerator' ratelimit in case of error

https://gerrit.wikimedia.org/r/745257

Change 745257 merged by jenkins-bot:

[mediawiki/extensions/Wikibase@REL1_36] Hook incrementing 'wikibase-idgenerator' ratelimit in case of error

https://gerrit.wikimedia.org/r/745257