Remove Usage model references from create service, specs and other models

What does this MR do and why?

This merge request removes the usage of Ci::Catalog::Resources::Components::Usage model and related functionality from the codebase. The change eliminates a component usage tracking system that was storing detailed usage data for CI catalog resources. Instead, the code now relies solely on the LastUsage model to track component usage. The PR removes database associations between resources, components, and projects related to usage tracking, updates the CreateService to only record last usage information, and completely removes the Aggregator class that was responsible for processing and summarizing usage data. This simplification likely reduces database overhead and complexity by eliminating a partitioned table and its associated aggregation logic, while still maintaining basic usage tracking functionality through the remaining LastUsage model.

References

Screenshots or screen recordings

NA

How to set up and validate locally

  1. Pipeline should be 🍏
  2. Everything should be just like before without any regression.

MR acceptance checklist

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

Edited by Rajendra Kadam

Merge request reports

Loading