Uploaded image for project: 'ServiceMix Components'
  1. ServiceMix Components
  2. SMXCOMP-826

MailPollerEndpoint error in the processing of mail set mail as Read (use gmail - imaps)

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • servicemix-mail-2010.01
    • 2010.02
    • servicemix-mail
    • None
    • Ubuntu 32bits, tomcat gmail

    Description

      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); }

      }

      Attachments

        Activity

          People

            lhein Lars Heinemann
            felek RafaƂ Felczuk
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: