@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add a key to improve Diffusion's cache fill history query

Summary:
Ref T10560. I don't fully understand what MySQL is doing here, but it looks like this key improves the problematic dataset in practice.

(It makes sense that this key helps, I'm just not sure why the two separate keys and the UNION ALL are so bad.)

This key isn't hugely expensive to add, so we can try it and see if there are still issues.

Test Plan: Ran `bin/storage adjust`, saw key added to table. Used `SHOW CREATE TABLE ...` to verify the key exists. Used `EXPLAIN SELECT ...` to make sure MySQL actually uses it.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T10560

Differential Revision: https://secure.phabricator.com/D15460

+3
+3
src/applications/repository/storage/PhabricatorRepositorySchemaSpec.php
··· 155 155 'repositoryID' => array( 156 156 'columns' => array('repositoryID', 'pathID', 'commitSequence'), 157 157 ), 158 + 'key_history' => array( 159 + 'columns' => array('commitID', 'isDirect', 'changeType'), 160 + ), 158 161 )); 159 162 160 163 $this->buildRawSchema(