-
Notifications
You must be signed in to change notification settings - Fork 184
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
add indexes for common queries on ENT
Signed-off-by: pxp928 <parth.psu@gmail.com>
- Loading branch information
Showing
7 changed files
with
63 additions
and
2 deletions.
There are no files selected for viewing
12 changes: 12 additions & 0 deletions
12
pkg/assembler/backends/ent/migrate/migrations/20240716182144_ent_diff.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,12 @@ | ||
-- Create index "billofmaterials_artifact_id" to table: "bill_of_materials" | ||
CREATE INDEX "billofmaterials_artifact_id" ON "bill_of_materials" ("artifact_id") WHERE ((package_id IS NULL) AND (artifact_id IS NOT NULL)); | ||
-- Create index "billofmaterials_package_id" to table: "bill_of_materials" | ||
CREATE INDEX "billofmaterials_package_id" ON "bill_of_materials" ("package_id") WHERE ((package_id IS NOT NULL) AND (artifact_id IS NULL)); | ||
-- Create index "certifylegal_package_id" to table: "certify_legals" | ||
CREATE INDEX "certifylegal_package_id" ON "certify_legals" ("package_id") WHERE ((package_id IS NOT NULL) AND (source_id IS NULL)); | ||
-- Create index "dependency_dependent_package_version_id" to table: "dependencies" | ||
CREATE INDEX "dependency_dependent_package_version_id" ON "dependencies" ("dependent_package_version_id"); | ||
-- Create index "occurrence_artifact_id" to table: "occurrences" | ||
CREATE INDEX "occurrence_artifact_id" ON "occurrences" ("artifact_id"); | ||
-- Create index "query_occurrence_package_id" to table: "occurrences" | ||
CREATE INDEX "query_occurrence_package_id" ON "occurrences" ("package_id") WHERE ((package_id IS NOT NULL) AND (source_id IS NULL)); |
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 |
---|---|---|
@@ -1,5 +1,6 @@ | ||
h1:LXg/nYCsid8/s+ZoQXWKCibm+F9bkUi1BIhyu2GEPb8= | ||
h1:TKSr9lC5BbUWVZejxSWM7ok/sdxy/sTwD/QZYeCDRFQ= | ||
20240503123155_baseline.sql h1:oZtbKI8sJj3xQq7ibfvfhFoVl+Oa67CWP7DFrsVLVds= | ||
20240626153721_ent_diff.sql h1:FvV1xELikdPbtJk7kxIZn9MhvVVoFLF/2/iT/wM5RkA= | ||
20240702195630_ent_diff.sql h1:y8TgeUg35krYVORmC7cN4O96HqOc3mVO9IQ2lYzIzwg= | ||
20240712193834_ent_diff.sql h1:gBSeZwJhD3fL9E97DJIGevIwsbe64Lc0YQtxvwpd/Ss= | ||
20240716182144_ent_diff.sql h1:QaeD0+aY7RYQSvpoxLMfUrcwKIM9ZG++0cn8F5PkIRo= |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
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
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