Reference test table directly in label2test table#2390
Merged
josephsnyder merged 1 commit intoKitware:masterfrom Aug 27, 2024
Merged
Reference test table directly in label2test table#2390josephsnyder merged 1 commit intoKitware:masterfrom
josephsnyder merged 1 commit intoKitware:masterfrom
Conversation
1d0d6b3 to
cd1dfb2
Compare
josephsnyder
approved these changes
Aug 26, 2024
Member
josephsnyder
left a comment
There was a problem hiding this comment.
Test site works as expected! LGTM!
josephsnyder
requested changes
Aug 26, 2024
Member
josephsnyder
left a comment
There was a problem hiding this comment.
Actually, I can replicate the MySQL errors for queryTests in local testing. I'll see if I can figure out anything quickly
cd1dfb2 to
407c465
Compare
407c465 to
6542b3e
Compare
github-merge-queue bot
pushed a commit
that referenced
this pull request
Sep 18, 2024
#2390 accidentally changed the formatting of the labels attribute in the viewTest.php API response.
github-merge-queue bot
pushed a commit
that referenced
this pull request
Oct 10, 2024
#2390 added a migration which affects every row in the `label2test` table. MySQL is very inefficient at bulk updates, and real-world test have shown that the running time can be reduced by using small batches. This PR updates the migration to use a batching approach for both MySQL and Postgres.
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The
label2testtable currently relates labels to tests indirectly, storing the label ID, test output ID, and build ID, from which the test ID can be derived. By not referencing tests directly, the database is forced to perform suboptimal queries for some of our large pages.This PR removes the test output ID and build ID columns, and replaces them with a test ID column in preparation for larger upcoming changes to label-related tables. As part of this work, I set up eloquent relationships between the Test and Label models for future use. The functions deprecated in this PR will be removed in a separate PR.