improve error log when timing out while connecting to mail server
This commit is contained in:
parent
92551df979
commit
9e9c81c30b
|
@ -96,9 +96,12 @@ module Jobs
|
||||||
process_popmail(p)
|
process_popmail(p)
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
rescue Net::OpenTimeout => e
|
||||||
|
mark_as_errored!
|
||||||
|
Discourse.handle_job_exception(e, error_context(@args, "Connecting to '#{SiteSetting.pop3_polling_host}' for polling emails."))
|
||||||
rescue Net::POPAuthenticationError => e
|
rescue Net::POPAuthenticationError => e
|
||||||
mark_as_errored!
|
mark_as_errored!
|
||||||
Discourse.handle_job_exception(e, error_context(@args, "Signing in to poll incoming email"))
|
Discourse.handle_job_exception(e, error_context(@args, "Signing in to poll incoming emails."))
|
||||||
end
|
end
|
||||||
|
|
||||||
POLL_MAILBOX_ERRORS_KEY ||= "poll_mailbox_errors".freeze
|
POLL_MAILBOX_ERRORS_KEY ||= "poll_mailbox_errors".freeze
|
||||||
|
|
Loading…
Reference in New Issue