Switch self.table_name on push_rules to project_push_rules
### Summary As part of the effort to create dedicated tables for push rules (organization, group, and project), we migrated all project push rule records from the push_rules table to the new project_push_rules table. The migration is now complete: - Initial migration: !211812 and !212378 - Follow-up migration for missing records: !219705 All records have been successfully migrated and verified on postgres.ai. ### Implementation plan - [ ] **Phase 1: Switch reads(18.10)** - [x] **1-1: Set the foundation before switching read call sites: [MR](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/225456)** * Create FF `read_project_push_rules` (disabled by default) * Create `ProjectPushRule` model with `include PushRuleable` * Create `ProjectPushRuleFinder` * Add `has_one :project_push_rule` to Project * Update `predefined_push_rule` to read from `project_push_rules` behind FF - [ ] **1-2: Switch remaining read call sites: [MR in review](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/225826)** * `ee/lib/api/project_push_rule.rb` - GET, POST (existence check), PUT (existence check), DELETE (fetch) * `ee/app/controllers/ee/projects/settings/repository_controller.rb` - read path on page load * `ee/app/services/ee/branches/validate_new_service.rb` - branch name validation - [ ] **Phase 2: Switch writes(18.10): [MR in dev](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/225833)** * Create FF `write_project_push_rules` (disabled by default) * Switch all write call sites behind FF * DB sync triggers remain active as rollback safety net - [ ] **Phase 3: [FF rollout](https://gitlab.com/gitlab-org/gitlab/-/work_items/588983)(18.10)**(will be handled in a separate issue) * Rollout read_project_push_rules FF incrementally(50% → 75% → 100%) * Rollout write_project_push_rules FF 100% - [ ] **Phase 4: [FF cleanup](https://gitlab.com/gitlab-org/gitlab/-/work_items/592187)(19.1)**(will be handled in a separate issue) * Remove all FF conditionals, make new behaviour permanent - [ ] **Phase 5: [Trigger cleanup](https://gitlab.com/gitlab-org/gitlab/-/work_items/588979)(19.1)**(will be handled in a separate issue) * Remove `sync_project_push_rules_on_insert_update` and `sync_project_push_rules_on_delete` triggers ### Related issues - Parent epic: [[link to epic if applicable]](https://gitlab.com/groups/gitlab-org/-/work_items/15537) - Project push rule: https://gitlab.com/gitlab-org/gitlab/-/work_items/499156
issue