优化邮件发送失败处理
This commit is contained in:
parent
4210e4843b
commit
a7c8fc105f
|
@ -96,6 +96,7 @@ public class EmailService {
|
|||
unSentEmailSendRecord.setSentAt(new Date());
|
||||
unSentEmailSendRecord.setStatus(flag ? NotificationSystemConstant.EMAIL_SENT_SUCCESS : NotificationSystemConstant.EMAIL_SENT_FAIL);
|
||||
} catch (Exception e) {
|
||||
unSentEmailSendRecord.setStatus(NotificationSystemConstant.EMAIL_SENT_FAIL);
|
||||
logger.error("发送邮件失败,email: " + unSentEmailSendRecord.getEmail() + "\n" + e);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue