codeintel: Optimize UpdateDependencyNumReferences query
There are no commits yet
Push commits to the source branch or add previously merged commits to review them.
Created by: efritz
This query should do the same thing but should choose a much better query plan. This should take some pressure off of Postgres as the previous query is inefficient enough to create some LSIF processing back pressure, which we generally don't encounter.
Two changes help here:
UPDATE FROM
instead of a subselect, which kept scanning CTE resultsI've been trying a few queries on the Cloud database and I've taken some samples down from minutes to sub-second with these changes.
Push commits to the source branch or add previously merged commits to review them.