CommandFailedException“由于错误而无法发送某些FETCH响应”

时间:2019-06-12 13:18:47

标签: javamail imap

我正在使用Javamail 1.5.6侦听来自特定邮件帐户的传入IMAP消息。 某些消息总是来自同一发件人,当我尝试读取其大小时会显示错误,请参阅以下日志:

"11:48:28.876 E [JavaMail-EventQueue] it.cbt.mail.impl.IMAPFolderSynchronizer:65 - Error notifying message addition
"javax.mail.MessagingException: A588 NO some FETCH responses could not be transmitted due to errors
        at com.sun.mail.imap.IMAPMessage.loadEnvelope(IMAPMessage.java:1450)
        at com.sun.mail.imap.IMAPMessage.getSize(IMAPMessage.java:491)
        at it.cbt.mail.impl.IMAPFolderSynchronizer.messagesAdded(IMAPFolderSynchronizer.java:54)
        at javax.mail.event.MessageCountEvent.dispatch(MessageCountEvent.java:153)
        at javax.mail.EventQueue.run(EventQueue.java:168)
        at java.lang.Thread.run(Thread.java:748)
Caused by: com.sun.mail.iap.CommandFailedException: A588 NO some FETCH responses could not be transmitted due to errors
        at com.sun.mail.iap.Protocol.handleResult(Protocol.java:396)
        at com.sun.mail.imap.IMAPMessage.loadEnvelope(IMAPMessage.java:1445)
        ... 5 common frames omitted
11:48:28.876 D [JavaMail-EventQueue] my.package.IncomingMailServiceImpl:182 - Notice "cannot map message section for parsing"

我认为这是一个邮件服务器错误,但是,如果我登录到邮件Web客户端,我可以正确看到那些在使用Javamail时失败的消息,因此我对真正问题的原因感到困惑。 你有遇到这个问题吗?

谢谢,再见

1 个答案:

答案 0 :(得分:0)

几乎可以肯定,这是邮件服务器中的错误。 JavaMail FAQ告诉您如何work around IMAP server bugs