2018-11-08 19:23:39 +05:30
|
|
|
# frozen_string_literal: true
|
|
|
|
|
2018-03-17 18:26:18 +05:30
|
|
|
module Gitlab
|
|
|
|
module GithubImport
|
|
|
|
module Queue
|
|
|
|
extend ActiveSupport::Concern
|
|
|
|
|
|
|
|
included do
|
|
|
|
queue_namespace :github_importer
|
|
|
|
|
|
|
|
# If a job produces an error it may block a stage from advancing
|
|
|
|
# forever. To prevent this from happening we prevent jobs from going to
|
|
|
|
# the dead queue. This does mean some resources may not be imported, but
|
|
|
|
# this is better than a project being stuck in the "import" state
|
|
|
|
# forever.
|
|
|
|
sidekiq_options dead: false, retry: 5
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|
|
|
|
end
|