-
Notifications
You must be signed in to change notification settings - Fork 356
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
perf: add indexes to tasks and allocations #8757
Conversation
✅ Deploy Preview for determined-ui canceled.
|
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #8757 +/- ##
==========================================
- Coverage 47.70% 47.70% -0.01%
==========================================
Files 1049 1049
Lines 167250 167250
Branches 2241 2243 +2
==========================================
- Hits 79792 79791 -1
- Misses 87300 87301 +1
Partials 158 158
Flags with carried forward coverage won't be shown. Click here to find out more. |
Example query on anon db without index
after
|
@@ -0,0 +1,3 @@ | |||
CREATE INDEX ix_allocations_task_id ON allocations USING btree (task_id); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit (non-blocking): btree
is the default index method, so you can just do CREATE INDEX ix_allocations_task_id ON allocations (task_id)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess there is a very slight argument for keeping the index type explicit?
It seems we do both in the codebase a bunch
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks for adding an example of the time cost decrease!
22836cf
to
a08e75d
Compare
Description
Enriching experiments was not using any indexes which we should defiantly add.
Test Plan
No tests needed besides like the cluster not breaking
Commentary (optional)
Checklist
docs/release-notes/
.See Release Note for details.
Ticket