Skip to content

Raise exception if any namespaces runner minutes were not reset

What does this MR do?

Raises an exception if any of the updates in the db transaction fail during a batch of namespaces having ci shared runner minutes reset during the ClearSharedRunnersMinutesWorker perform method

Based on this comment from the original issue #35878 :

Fabio Pitino 🔴 @fabiopitino Developer

My 2 cents. These type of issues are hard to investigate. When looking for errors in Sentry I don't see anything: https://sentry.gitlab.net/gitlab/gitlabcom/?query=is%3Aunresolved+ClearSharedRunnersMinutesWorker&statsPeriod=14d. I think we could add a sanity check after resetting minutes for a namespace and log the namespace that failed having the minutes reset. In this case we (1) don't need to get customers to report the issue to us and (2) we can see how many customers are actually impacted.

Closes #35878

Screenshots

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:

  • Label as security and @ mention @gitlab-com/gl-security/appsec
  • The MR includes necessary changes to maintain consistency between UI, API, email, or other methods
  • Security reports checked/validated by a reviewer from the AppSec team
Edited by Michael Kozono

Merge request reports