解决报错:com.sun.mail.smtp.SMTPSendFailedException: 451 5.7.3 STARTTLS is required to send mail
在使用ApacheCommonsEmail依赖通过微软Outlook邮箱发送邮件时连接服务器失败并抛出了这个异常查看该依赖源码后发现有email.setStartTLSEnabled()这个方法,于是试着启用了以下,然后成功解决了问题email.setStartTLSEnabled(true);问题分析:在使用ApacheCommonsEmail及之外的其他邮箱操作依赖时,发生此报错也都是因为没有