Rename project argument to container for all IssuableBaseService services
All issuable services end up inheriting from `IssuableBaseService` that inherits from `BaseProjectService`. Considering that want to have work items at group level, we would need all the `Issue` related services to be able to reference both a `project` and a `group`. Given that we have a `BaseContainerService` I think it would make sense to have `IssuableBaseService` inherit from `BaseContainerService` and have a couple `project` and `group` methods within `BaseContainerService` for backward compatibility. At the same time in all services we do pass in `project:` argument in the `initialize` method and it will be confusing, akward and just weird to pass a `group` instance into `project:` named argument. So we would want to rename the `project:` argument on `IssuableBaseService` to `container` to fit the more generic purpose. So I thought I'd do just that and opened an MR with that change: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/111663 The MR passes all the specs, but it is huge, so I do not think there will be many willing to review and approve this :laughing: . So I am now thinking of splitting it into several issues and MRs to make the reviwing more manageable. I am thinking of splitting this rename into the following issues that can then be broken down even further if possible into tasks based on direct children of `IssuableBaseService` ##### IssuableBaseService ```ruby pry(main)> IssuableBaseService.subclasses.collect {|s| {s.name => s.descendants.count} } => [{"Issuable::DestroyService"=>1}, {"Issuable::Clone::BaseService"=>3}, {"Issues::BaseService"=>15}, {"TasksToBeDone::BaseService"=>3}, {"MergeRequests::BaseService"=>33}, {"Epics::BaseService"=>6}] ``` Some of the bigger ones like `Issues::BaseService` and `MergeRequests::BaseService` can be broken down even further into smaller pieces. E.g. ##### Issues::BaseService ```ruby [24] pry(main)> Issues::BaseService.subclasses.collect {|s| {s.name => s.descendants.count} } => [{"Issues::BuildService"=>2}, {"Issues::CloseService"=>0}, {"Issues::RelatedBranchesService"=>0}, {"Issues::AfterCreateService"=>0}, {"Issues::ReorderService"=>0}, {"Issues::CreateService"=>1}, {"Issues::DuplicateService"=>0}, {"Issues::ReopenService"=>0}, {"Issues::ReferencedMergeRequestsService"=>0}, {"Issues::UpdateService"=>1}, {"Issues::ZoomLinkService"=>0}] ``` ##### MergeRequests::BaseService ```ruby [25] pry(main)> MergeRequests::BaseService.subclasses.collect {|s| {s.name => s.descendants.count} } => [{"MergeRequests::AfterCreateService"=>0}, {"MergeRequests::AddTodoWhenBuildFailsService"=>0}, {"MergeRequests::ExecuteApprovalHooksService"=>0}, {"MergeRequests::CreatePipelineService"=>0}, {"MergeRequests::CreateService"=>1}, {"MergeRequests::CreateApprovalEventService"=>0}, {"MergeRequests::MarkReviewerReviewedService"=>0}, {"MergeRequests::RebaseService"=>0}, {"MergeRequests::PushedBranchesService"=>0}, {"MergeRequests::ReopenService"=>0}, {"MergeRequests::HandleAssigneesChangeService"=>0}, {"MergeRequests::ResolvedDiscussionNotificationService"=>0}, {"MergeRequests::RequestReviewService"=>0}, {"MergeRequests::RefreshService"=>0}, {"MergeRequests::AddContextService"=>0}, {"MergeRequests::MergeBaseService"=>3}, {"MergeRequests::SquashService"=>0}, {"MergeRequests::RemoveApprovalService"=>0}, {"MergeRequests::UpdateService"=>3}, {"MergeRequests::CloseService"=>0}, {"MergeRequests::BuildService"=>0}, {"MergeRequests::ApprovalService"=>0}, {"MergeRequests::PostMergeService"=>0}, {"MergeRequests::RetargetChainService"=>0}, {"MergeRequests::ResetApprovalsService"=>0}, {"MergeRequests::StreamApprovalAuditEventService"=>0}] ``` Note that this involves changing the `initialize` method signature as well as places from where given services are initialized, including specs. @gitlab-org/plan-stage/backend-engineers please do chime in if you think this is a bad idea or if you are willing to review and approve the original MR https://gitlab.com/gitlab-org/gitlab/-/merge_requests/111663+ :laughing:
epic