blob: 12084ef5cb23c3f805b75364d83956ae8186046f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
# frozen_string_literal: true
module Packages
module Composer
class CacheUpdateWorker
include ApplicationWorker
sidekiq_options retry: 3
feature_category :package_registry
idempotent!
def perform(project_id, package_name, last_page_sha)
project = Project.find_by_id(project_id)
return unless project
Gitlab::Composer::Cache.new(project: project, name: package_name, last_page_sha: last_page_sha).execute
rescue StandardError => e
Gitlab::ErrorTracking.log_exception(e, project_id: project_id)
end
end
end
end
|