forked from sourcegraph/sourcegraph
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[rank] adds path count table for ranking (sourcegraph#47994)
Adds table to count the global paths that will be used in the ranking background jobs. ## Test plan Tested manually. <!-- All pull requests REQUIRE a test plan: https://docs.sourcegraph.com/dev/background-information/testing_principles -->
- Loading branch information
1 parent
a6181dc
commit b70e55a
Showing
6 changed files
with
171 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1 change: 1 addition & 0 deletions
1
migrations/frontend/1677008591_add_codeintel_rank_path_counts_inputs/down.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
DROP TABLE IF EXISTS codeintel_ranking_path_counts_inputs; |
2 changes: 2 additions & 0 deletions
2
migrations/frontend/1677008591_add_codeintel_rank_path_counts_inputs/metadata.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
name: add_codeintel_rank_path_counts_inputs | ||
parents: [1677005673] |
10 changes: 10 additions & 0 deletions
10
migrations/frontend/1677008591_add_codeintel_rank_path_counts_inputs/up.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
CREATE TABLE IF NOT EXISTS codeintel_ranking_path_counts_inputs ( | ||
id bigserial PRIMARY KEY NOT NULL, | ||
repository text NOT NULL, | ||
document_path text NOT NULL, | ||
count int NOT NULL, | ||
graph_key text NOT NULL, | ||
processed boolean NOT NULL DEFAULT false | ||
); | ||
|
||
CREATE INDEX IF NOT EXISTS codeintel_ranking_path_counts_inputs_graph_key_and_repository ON codeintel_ranking_path_counts_inputs (graph_key, repository); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters