To find changes relevant to wiki x, we should be able to join wb_changes against wb_changes_subscriptions. This would remove the need for programmatic filtering.
Description
Event Timeline
Yes, we are actually working on this right now (see the dependency T109825: [Task] Use uppercase entity ID in wb_changes table.).
As far as I can see T111161: Subscribe client wikis immediately after adding sitelinks is the only blocker left for this.
Rising priority: Dispatching is an ongoing problem and this will fix (most of?) this.
Also I guess the number of changes that actually need dispatching has decreased (as we have a lot of entities not used on any sister project) these days. Thus fixing this and increasing the job batch size (or completely changing how that works) would fix the dispatching bottleneck for now.
I think with the refactoring of how change dispatching works in Q3 2021, this is no longer applicable. Now RecentChangeSaveHookHandler schedules one job per change as long as there is any wiki subscribed to that entity. That happens in the process when the change has been made.