2020-03-24 09:09:25 +00:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2021-04-22 00:10:01 +00:00
|
|
|
# Deprecated, to be removed in %14.0 as part of https://gitlab.com/groups/gitlab-org/-/epics/4280
|
2022-11-04 09:11:46 +00:00
|
|
|
# Also see https://gitlab.com/gitlab-org/gitlab/-/issues/366573
|
2020-03-24 09:09:25 +00:00
|
|
|
class ClusterUpdateAppWorker # rubocop:disable Scalability/IdempotentWorker
|
|
|
|
UpdateAlreadyInProgressError = Class.new(StandardError)
|
|
|
|
|
|
|
|
include ApplicationWorker
|
2021-07-21 12:09:35 +00:00
|
|
|
|
|
|
|
data_consistency :always
|
2020-03-24 09:09:25 +00:00
|
|
|
include ClusterQueue
|
|
|
|
include ClusterApplications
|
|
|
|
include ExclusiveLeaseGuard
|
|
|
|
|
|
|
|
sidekiq_options retry: 3, dead: false
|
2020-06-12 12:08:56 +00:00
|
|
|
loggable_arguments 0, 3
|
2020-03-24 09:09:25 +00:00
|
|
|
|
|
|
|
LEASE_TIMEOUT = 10.minutes.to_i
|
|
|
|
|
2022-11-04 09:11:46 +00:00
|
|
|
def perform(app_name, app_id, project_id, scheduled_time); end
|
2020-03-24 09:09:25 +00:00
|
|
|
end
|