Commit fde54e2c authored by Gabriel Mazetto's avatar Gabriel Mazetto

Added GeoBulkNotifyWorker to sidekiq-cron

parent ca389e1f
class GeoRepositoryUpdateWorker
include Sidekiq::Worker
sidekiq_options queue: :default
def perform
return unless Gitlab::Geo.enabled?
Geo::NotifyNodesService.new.execute
end
end
......@@ -2,9 +2,9 @@ class GeoRepositoryUpdateWorker
include Sidekiq::Worker
include Gitlab::ShellAdapter
sidekiq_options queue: :gitlab_shell
sidekiq_options queue: :default
attr_accessor :project, :repository, :current_user
attr_accessor :project
def perform(project_id)
@project = Project.find(project_id)
......
......@@ -196,6 +196,11 @@ production: &base
ldap_sync_worker:
cron: "30 1 * * *"
# Gitlab Geo nodes notification worker
# NOTE: This will only take effect if Geo is enabled
geo_bulk_notify_worker:
cron: "*/10 * * * * *"
#
# 2. GitLab CI settings
......
......@@ -331,6 +331,9 @@ Settings.cron_jobs['update_all_mirrors_worker']['job_class'] = 'UpdateAllMirrors
Settings.cron_jobs['ldap_sync_worker'] ||= Settingslogic.new({})
Settings.cron_jobs['ldap_sync_worker']['cron'] ||= '30 1 * * *'
Settings.cron_jobs['ldap_sync_worker']['job_class'] = 'LdapSyncWorker'
Settings.cron_jobs['geo_bulk_notify_worker'] ||= Settingslogic.new({})
Settings.cron_jobs['geo_bulk_notify_worker']['cron'] ||= '*/10 * * * * *'
Settings.cron_jobs['geo_bulk_notify_worker']['job_class'] ||= 'GeoBulkNotifyWorker'
#
# GitLab Shell
......
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