diff --git a/app/jobs/sync_forge_job.rb b/app/jobs/sync_forge_job.rb index aa649a5..a8fe913 100644 --- a/app/jobs/sync_forge_job.rb +++ b/app/jobs/sync_forge_job.rb @@ -19,7 +19,6 @@ class SyncForgeJob < ApplicationJob if new_user.present? ActiveRecord::Base.transaction do begin - Watcher&.where(user_id: user_old_id).update_all(user_id: new_user.id) ProjectTrend&.where(user_id: user_old_id).update_all(user_id: new_user.id) sync_roles(roles_params, platform) @@ -41,12 +40,12 @@ class SyncForgeJob < ApplicationJob end end rescue Exception => e - Rails.logger.info("#######_________user__sync__failed__#########{e}") + Rails.logger.info("#######_______forge_new_user_sync_failed___#########{e}") raise ActiveRecord::Rollback end end else - Rails.logger.info("############___________________########{user_old_id}创建失败") + Rails.logger.info("############____forge_new_user_create_failed_____#######old_user_id:-#{user_old_id}") end end end diff --git a/config/sidekiq.yml b/config/sidekiq.yml index 4ceb7b3..dda6a32 100644 --- a/config/sidekiq.yml +++ b/config/sidekiq.yml @@ -1,6 +1,7 @@ :concurrency: <%= ENV["sidekiq_threads"] || 20 %> :pidfile: tmp/pids/sidekiq.pid :logfile: log/sidekiq.log +:timeout: 30 :queues: - [default, 3] - [searchkick, 10]