Skip to content

Artifact Registry base service: remove unneeded constants

David Fernandez requested to merge 439565-follow-up into master

🎈 Context

Follow up of !143359 (comment 1758827446).

In that MR, we added the services layer for the Google Cloud Artifact Registry support. That's issue #439565 (closed).

At that time, we introduced a base class that contains all the common/shared logic. Among these, we have some common validation that can return ServiceResponse.error errors. Those errors being fixed have been stored in a constant structure. They are two error responses that are still declared independently as they are not part of the constant.

This MR puts these 2 service error response in that constant.

🔬 What does this MR do and why?

  • Update ee/app/services/google_cloud_platform/artifact_registry/base_project_service.rb to have all common service error response in the ERRORS constant.
  • Update the related spec.

These services are gated behind a feature flag: no changelog here.

🛵 MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

📺 Screenshots or screen recordings

🦄

Before After

How to set up and validate locally

See !143359 (merged)

Merge request reports