Skip to content

Skip archiving job traces after five failed attempts

Marius Bobin requested to merge ci-skip-processing-failed-traces into master

What does this MR do?

Related to #296918 (closed)

This MR builds on top of !68171 (merged)

We start tracking the failed attempts of archiving build traces and if a job reaches five attempts we skip processing it.

Screenshots or Screencasts (strongly suggested)

$ VERSION=20210824105038 bin/rake db:migrate:up

== 20210824105038 AddTimestampColumnsToCiBuildTraceMetadata: migrating ========
-- add_column(:ci_build_trace_metadata, :last_archival_attempt_at, :datetime_with_timezone)
   -> 0.0027s
-- add_column(:ci_build_trace_metadata, :archived_at, :datetime_with_timezone)
   -> 0.0011s
== 20210824105038 AddTimestampColumnsToCiBuildTraceMetadata: migrated (0.0040s)
$ VERSION=20210824105038 bin/rake db:migrate:down

== 20210824105038 AddTimestampColumnsToCiBuildTraceMetadata: reverting ========
-- remove_column(:ci_build_trace_metadata, :archived_at, :datetime_with_timezone)
   -> 0.0021s
-- remove_column(:ci_build_trace_metadata, :last_archival_attempt_at, :datetime_with_timezone)
   -> 0.0007s
== 20210824105038 AddTimestampColumnsToCiBuildTraceMetadata: reverted (0.0068s)

How to setup and validate locally (strongly suggested)

Does this MR meet the acceptance criteria?

Conformity

Availability and Testing

Security

Does this MR contain changes to processing or storing of credentials or tokens, authorization and authentication methods or other items described in the security review guidelines? If not, then delete this Security section.

  • 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 Marius Bobin

Merge request reports