Commit 1574963c authored by Erick Bajao's avatar Erick Bajao

Mark daily code coverage worker as idempotent

parent 0438e1c0
...@@ -611,7 +611,7 @@ ...@@ -611,7 +611,7 @@
:urgency: :default :urgency: :default
:resource_boundary: :unknown :resource_boundary: :unknown
:weight: 1 :weight: 1
:idempotent: :idempotent: true
- :name: pipeline_cache:expire_job_cache - :name: pipeline_cache:expire_job_cache
:feature_category: :continuous_integration :feature_category: :continuous_integration
:has_external_dependencies: :has_external_dependencies:
......
...@@ -5,6 +5,8 @@ module Ci ...@@ -5,6 +5,8 @@ module Ci
include ApplicationWorker include ApplicationWorker
include PipelineBackgroundQueue include PipelineBackgroundQueue
idempotent!
def perform(pipeline_id) def perform(pipeline_id)
Ci::Pipeline.find_by_id(pipeline_id).try do |pipeline| Ci::Pipeline.find_by_id(pipeline_id).try do |pipeline|
Ci::DailyCodeCoverageService.new.execute(pipeline) Ci::DailyCodeCoverageService.new.execute(pipeline)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment