PERF: lower the priority on user emails
User emails can wait behind other regular jobs, they are usually somewhat slower as they involve smtp transactions
This commit is contained in:
parent
9e2131ace8
commit
24abf38d38
|
@ -6,6 +6,8 @@ module Jobs
|
|||
# Asynchronously send an email to a user
|
||||
class UserEmail < Jobs::Base
|
||||
|
||||
sidekiq_options queue: 'low'
|
||||
|
||||
def execute(args)
|
||||
raise Discourse::InvalidParameters.new(:user_id) unless args[:user_id].present?
|
||||
raise Discourse::InvalidParameters.new(:type) unless args[:type].present?
|
||||
|
|
Loading…
Reference in New Issue