PhotoDNA has a rate limit of 5 requests per second (docs). We need to update the ModerateExistingFiles.php maintenance script to ensure it does not exceed this limit.
The way we've discussed doing this is:
- Place the existing job queue implementation behind a command line flag, like --use-job-queue, in case we need it again someday.
- The new implementation should iterate over files synchronously rather than dispatching them to the job queue for asynchronous processing
- The new implementation could use Guzzle's ability to batch multiple HTTP requests (documentation) if we can do so with MediaWiki's HttpRequestFactory. If we can't use HttpRequestFactory for this, then let's just send one item at a time. Either way, we need some timers to track that we don't send more than 5 items per second.
T341221 and T336576 have been folded into this ticket
