Replace hardcoded table names with arel values
What does this MR do and why?
Related to #358943 (closed)
I've noticed this while working on !92440 (diffs, comment 1026630646) and it's something worth fixing for the future work on CI data partitioning.
Before:
[2] pry(main)> Ci::Pipeline.created_after(1.day.ago).to_sql
=> "SELECT \"ci_pipelines\".* FROM \"ci_pipelines\" WHERE (ci_pipelines.created_at > '2022-07-14 10:22:28.708263')"
[3] pry(main)> Ci::Pipeline.created_before_id(1000).to_sql
=> "SELECT \"ci_pipelines\".* FROM \"ci_pipelines\" WHERE (ci_pipelines.id < 1000)"
After:
[1] pry(main)> Ci::Pipeline.created_after(1.day.ago).to_sql
=> "SELECT \"ci_pipelines\".* FROM \"ci_pipelines\" WHERE \"ci_pipelines\".\"created_at\" > '2022-07-14 10:27:51.214217'"
[2] pry(main)> Ci::Pipeline.created_before_id(1000).to_sql
=> "SELECT \"ci_pipelines\".* FROM \"ci_pipelines\" WHERE \"ci_pipelines\".\"id\" < 1000"
Screenshots or screen recordings
These are strongly recommended to assist reviewers and reduce the time to merge your change.
How to set up and validate locally
Numbered steps to set up and validate the change are strongly suggested.
MR acceptance checklist
This checklist encourages us to confirm any changes have been analyzed to reduce risks in quality, performance, reliability, security, and maintainability.
-
I have evaluated the MR acceptance checklist for this MR.
Merge request reports
Activity
changed milestone to %15.5
added VerifyP2 backend ciscaling devopsverify grouppipeline execution sectionops typemaintenance workflowready for development + 1 deleted label
assigned to @mbobin
Suggested Reviewers (beta)
The individuals below may be good candidates to participate in the review based on various factors.
You can use slash commands in comments to quickly assign
/assign_reviewer @user1
.Suggested Reviewers @rspeicher
,@psimyn
,@tkuah
,@marin
,@mayra-cabrera
If you do not believe these suggestions are useful, please apply the label Bad Suggested Reviewer. You can also provide feedback for this feature on this issue:
https://gitlab.com/gitlab-org/gitlab/-/issues/357923
.Automatically generated by Suggested Reviewers Bot - an experimental ML-based recommendation engine created by ~"group::applied ml".
Reviewer roulette
Changes that require review have been detected!
Please refer to the table below for assigning reviewers and maintainers suggested by Danger in the specified category:
Category Reviewer Maintainer backend Steve Abrams ( @sabrams
) (UTC-6, 9 hours behind@mbobin
)Douglas Barbosa Alexandre ( @dbalexandre
) (UTC-3, 6 hours behind@mbobin
)To spread load more evenly across eligible reviewers, Danger has picked a candidate for each review slot, based on their timezone. Feel free to override these selections if you think someone else would be better-suited or use the GitLab Review Workload Dashboard to find other available reviewers.
To read more on how to use the reviewer roulette, please take a look at the Engineering workflow and code review guidelines. Please consider assigning a reviewer or maintainer who is a domain expert in the area of the merge request.
Once you've decided who will review this merge request, assign them as a reviewer! Danger does not automatically notify them for you.
If needed, you can retry the
danger-review
job that generated this comment.Generated by
Dangermarked the checklist item I have evaluated the MR acceptance checklist for this MR. as completed
removed VerifyP2 label
removed workflowready for development label
changed milestone to %15.2
- Resolved by Douglas Barbosa Alexandre
@sabrams could you do the first review here?
requested review from @sabrams
added maintenancerefactor label
mentioned in merge request !92440 (closed)
Allure report
allure-report-publisher
generated test report!review-qa-blocking:
test report for 0bc6ee3bexpand test summary
+-----------------------------------------------------------------------------------------+ | suites summary | +------------------------------------+--------+--------+---------+-------+-------+--------+ | | passed | failed | skipped | flaky | total | result | +------------------------------------+--------+--------+---------+-------+-------+--------+ | Create | 23 | 0 | 2 | 23 | 25 | ❗ | | Plan | 47 | 0 | 1 | 47 | 48 | ❗ | | Secure | 2 | 0 | 0 | 2 | 2 | ❗ | | Version sanity check | 0 | 0 | 1 | 0 | 1 | ➖ | | Manage | 38 | 0 | 2 | 40 | 40 | ❗ | | Verify | 12 | 0 | 1 | 12 | 13 | ❗ | | Feature flag handler sanity checks | 9 | 0 | 0 | 9 | 9 | ❗ | | Protect | 2 | 0 | 0 | 2 | 2 | ❗ | | Configure | 0 | 0 | 1 | 0 | 1 | ➖ | | Package | 0 | 0 | 1 | 0 | 1 | ➖ | +------------------------------------+--------+--------+---------+-------+-------+--------+ | Total | 133 | 0 | 9 | 135 | 142 | ❗ | +------------------------------------+--------+--------+---------+-------+-------+--------+
added 1 commit
- 0bc6ee3b - Replace hardcoded table names with arel values
@sabrams
, thanks for approving this merge request.This is the first time the merge request is approved. To ensure full test coverage, a new pipeline has been started.
For more info, please refer to the following links:
requested review from @dbalexandre and removed review request for @sabrams
mentioned in issue gitlab-com/www-gitlab-com#13277 (closed)
mentioned in commit 989056ea
Thanks, @mbobin! This LGTM, merged
added workflowstaging-canary label
added workflowcanary label and removed workflowstaging-canary label
added workflowstaging label and removed workflowcanary label
added workflowproduction label and removed workflowstaging label
added workflowpost-deploy-db-staging label and removed workflowproduction label
added workflowpost-deploy-db-production label and removed workflowpost-deploy-db-staging label
added releasedcandidate label
added releasedpublished label and removed releasedcandidate label
added CI data partitioning label
mentioned in epic &7522
added Category:Continuous Integration label and removed 1 deleted label
mentioned in merge request mbobin/headway!1 (closed)
mentioned in merge request gitlab-org/ci-cd/ops-eng-managers/headway!1 (merged)