The actor and comment views on the wiki replicas are slowed by a need to make subqueries against 8 other tables in order to determine which rows should and should not be visible on the replica service. With recent changes to the replica view schema, this problem has become much more visible.
The WMCS team has deployed a set of specialized views of these two tables that will allow individual queries to only be slowed by a single subquery against a related target, eg. a query for an actor mentioned in the log_actor field of the logging table could be made against actor_logging, which will only check against logic in the actor table--not 7 other tables that aren't related to the query. On the flip side the actor_logging view will only have rows that are exposed in the logging table.
For more information, see: https://wikitech.wikimedia.org/wiki/News/Actor_storage_changes_on_the_Wiki_R...
If other documentation about the Wiki Replicas on wikitech needs updating related to this change, we would like your help finding it! Please let us know on IRC, phab task, email or on wiki if you find things that need updating related to the actor and comment tables. A Phabricator task is already open to update the MediaWiki documentation related (https://phabricator.wikimedia.org/T225007), but it is likely that there are bits around wikitech to update as well.
Brooke Storm Operations Engineer Wikimedia Cloud Services bstorm@wikimedia.org mailto:bstorm@wikimedia.org IRC: bstorm_