mirror of
https://github.com/simple-login/app.git
synced 2024-11-13 04:04:55 +08:00
no need to raise error if email processing takes more than 60s
This commit is contained in:
parent
94ecdb0515
commit
efdb0a60d3
1 changed files with 1 additions and 7 deletions
|
@ -2432,13 +2432,7 @@ class MailHandler:
|
||||||
ret = handle(envelope, msg)
|
ret = handle(envelope, msg)
|
||||||
elapsed = time.time() - start
|
elapsed = time.time() - start
|
||||||
|
|
||||||
# use error log if taking more than 1 minute
|
LOG.i(
|
||||||
if elapsed > 60:
|
|
||||||
log_f = LOG.e
|
|
||||||
else:
|
|
||||||
log_f = LOG.i
|
|
||||||
|
|
||||||
log_f(
|
|
||||||
"Finish mail_from %s, rcpt_tos %s, takes %s seconds <<===",
|
"Finish mail_from %s, rcpt_tos %s, takes %s seconds <<===",
|
||||||
envelope.mail_from,
|
envelope.mail_from,
|
||||||
envelope.rcpt_tos,
|
envelope.rcpt_tos,
|
||||||
|
|
Loading…
Reference in a new issue