TRT-1989: remove ProwJobRunTest during partition migration#3333
TRT-1989: remove ProwJobRunTest during partition migration#3333neisw wants to merge 2 commits intoopenshift:mainfrom
Conversation
|
Pipeline controller notification For optional jobs, comment This repository is configured in: automatic mode |
|
@neisw: This pull request references TRT-1989 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Organization UI (inherited) Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
🚧 Files skipped from review as they are similar to previous changes (1)
WalkthroughRemoved Changes
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes 🚥 Pre-merge checks | ✅ 4✅ Passed checks (4 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 golangci-lint (2.11.3)Error: can't load config: unsupported version of the configuration: "" See https://golangci-lint.run/docs/product/migration-guide for migration instructions Comment |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: neisw The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
|
@neisw: This pull request references TRT-1989 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@pkg/db/db.go`:
- Around line 112-115: The TODO and commented-out models
(&models.ProwJobRunTest{}, &models.ProwJobRunTestOutput{}) remove these tables
from AutoMigrate and leave creation unclear; either re-add them to the
AutoMigrate call in pkg/db/db.go (so AutoMigrate includes ProwJobRunTest and
ProwJobRunTestOutput until partitioning is implemented) or implement an explicit
SQL migration/initialization routine that creates those tables (documenting that
path). Locate the AutoMigrate invocation that previously referenced
ProwJobRunTest and ProwJobRunTestOutput and either restore those model types
into AutoMigrate or add a clear migration function that runs CREATE TABLE for
ProwJobRunTest and ProwJobRunTestOutput and update the TODO to reference the
chosen approach.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Organization UI (inherited)
Review profile: CHILL
Plan: Pro
Run ID: 26cb8100-2410-462d-bf75-31c02e1ad93b
📒 Files selected for processing (2)
pkg/db/db.gopkg/db/models/prow.go
|
Scheduling required tests: |
|
@neisw: This pull request references TRT-1989 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In `@pkg/db/db.go`:
- Around line 120-123: The loop is calling d.DB.AutoMigrate(model) on the
wrapper struct instead of the actual model instance, so replace the AutoMigrate
call to pass the inner model (e.g., model.model) rather than the wrapper; keep
the HasTable check using model.tableName and the existing error handling,
ensuring ProwJobRunTest and ProwJobRunTestOutput (and any other entries in
modelsToInitialize) are migrated using their real model values.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Repository YAML (base), Organization UI (inherited)
Review profile: CHILL
Plan: Pro
Run ID: d6d867b2-cc2a-4d34-9f45-e9d54863f430
📒 Files selected for processing (1)
pkg/db/db.go
|
Scheduling required tests: |
577c26b to
4c34d41
Compare
|
@neisw: This pull request references TRT-1989 which is a valid jira issue. Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.22.0" version, but no target version was set. DetailsIn response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository. |
|
Scheduling required tests: |
|
@neisw: all tests passed! Full PR test history. Your PR dashboard. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. I understand the commands that are listed here. |
|
/hold |
Removes tables targeted for partitioning from being managed automatically via gorm
Summary by CodeRabbit
Chores
Documentation