Homec4science

Add a `(dst, type, src)` key to Differential's edge table

Authored by epriestley <git@epriestley.com> on Oct 5 2013, 13:49.

Description

Add a (dst, type, src) key to Differential's edge table

Summary:
Ref T1279. This came to me in a dream.

The existing differential_relationship table has an (objectPHID, type) column, which theoretically is useful for queries like "revisions with X as a reviewer". In practice, I'm not sure it gets used much, but I can get it to show up in at least some query plans.

Add a similar index to the edge table. This sequences before D7227, which actually migrates the data.

Test Plan:

  • Ran bin/storage upgrade.
  • EXPLAIN'd a bunch of queries against different versions of the schema, this seemed helpful overall.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T1279

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

Conflicts:
src/infrastructure/storage/patch/PhabricatorBuiltinPatchList.php

Details

Committed
epriestley <git@epriestley.com>Oct 5 2013, 22:53
Pushed
aubortJan 31 2017, 17:16
Parents
rPHe6d8e1a00ac4: Make Herald rules obey policies during application
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPHbd8071bb3350: Add a `(dst, type, src)` key to Differential's edge table (authored by epriestley <git@epriestley.com>).Oct 5 2013, 22:53