debian-mirror-gitlab/app/workers/concerns/waitable_worker.rb
2023-04-23 21:23:45 +05:30

13 lines
267 B
Ruby

# frozen_string_literal: true
module WaitableWorker
extend ActiveSupport::Concern
def perform(*args)
notify_key = args.pop if Gitlab::JobWaiter.key?(args.last)
super(*args)
ensure
Gitlab::JobWaiter.notify(notify_key, jid) if notify_key
end
end