mirror of
https://gh-proxy.org/https://github.com/klinsmaya/multica.git
synced 2026-11-08 01:16:45 +08:00
* perf(db): index GitHub PR address lookups (MUL-7556) Co-authored-by: multica-agent <[email protected]> * perf(db): narrow GitHub PR address index (MUL-7556) Co-authored-by: multica-agent <[email protected]> * fix(migrations): renumber GitHub PR address index Co-authored-by: multica-agent <[email protected]> --------- Co-authored-by: Forge-Boy <[email protected]> Co-authored-by: multica-agent <[email protected]>
7 lines
445 B
SQL
7 lines
445 B
SQL
-- Match the pull-request address used by snapshot refreshes without making the
|
|
-- GitHub App installation, which is an authorization scope, part of identity.
|
|
-- Leading with pr_number prevents the head-SHA lookup, which has no PR number,
|
|
-- from preferring this index over its selective head_sha index.
|
|
CREATE INDEX CONCURRENTLY IF NOT EXISTS idx_github_pull_request_pr_owner_repo
|
|
ON github_pull_request (pr_number, repo_owner, repo_name);
|