[
https://issues.apache.org/jira/browse/SMXCOMP-826?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12966511#action_12966511
]
Lars Heinemann commented on SMXCOMP-826:
----------------------------------------
I am really wondering about that. We do not set the read/seen flag in that case
so it is usually not needed to explicitly set the SEEN flag to false as it
still is unseen.
> MailPollerEndpoint error in the processing of mail set mail as Read (use
> gmail - imaps)
> ---------------------------------------------------------------------------------------
>
> Key: SMXCOMP-826
> URL: https://issues.apache.org/jira/browse/SMXCOMP-826
> Project: ServiceMix Components
> Issue Type: Bug
> Components: servicemix-mail
> Affects Versions: servicemix-mail-2010.01
> Environment: Ubuntu 32bits, tomcat gmail
> Reporter: RafaĆ Felczuk
>
> This issue i observed on the gmail.
> Incorrect processing of mail, it sets the read. A mail will never be
> processed again.
> Poll method:
> // now check if delivery succeeded or went wrong
> if (io.getStatus() == ExchangeStatus.ERROR) {
> Exception e = io.getError();
> if (e == null) {
> e = new JBIException("Unexpected error
> occured...");
> }
> // I propose here
> // mailMsg.setFlag(Flags.Flag.SEEN, false);
> // or method that user can overide
> throw e;
> } else {
> // then mark the mail as processed (only if no errors)
> if (deleteProcessedMessages) {
> // processed messages have to be marked as deleted
> mailMsg.setFlag(Flags.Flag.DELETED, true);
> } else {
> // processed messages have to be marked as seen
> mailMsg.setFlag(Flags.Flag.SEEN, true);
> }
> // remember the processed mail if needed
> if (isProcessOnlyUnseenMessages() && isPopProtocol &&
> uid != null) {
> // POP3 doesn't support flags, so we need to
> // remember processed mails
> this.seenMessages.add(uid);
> }
> }
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.