Rolling back creation of a mail-item when no chunks were added to it

XMLWordPrintable

    • 3
    • Severity 2 - Major
    • 2

      Issue Summary

      This is reproducible on Data Center: no

      Steps to Reproduce

      None.
      Related to JSDSERVER-11760

      Expected Results

      When we find any email items with ZERO mail chunks, we should delete those email items totally. We should also mark the email as UNREAD in the inbox. In the next run it should try to fetch the email again. 

      Actual Results

      We find that email items with Zero mail chunks are not deleted thus mail handler try to reprocess them and fails each time. This decrease overall efficiency of mail-handler processing the newer email.

      Workaround

      Manually check output of following query. Then update AO_2C4E5C_MAILITEM with STATUS as PROCESSED. This is to avoid mailprocessor processing these email with null mailchunks.

       select * from "AO_2C4E5C_MAILITEM" emailItem LEFT OUTER JOIN "AO_2C4E5C_MAILITEMCHUNK" chunk ON emailItem."ID" = chunk."MAIL_ITEM_ID" WHERE chunk."MAIL_ITEM_ID" is NULL 
      
      # From output of select query, get the mail id.
      
      UPDATE "AO_2C4E5C_MAILITEM" SET "STATUS" = 'PROCESSED' where "ID" in (<mailID1>,<mailID2>,<mailID3>,.......);

              Assignee:
              Tripta Kaur
              Reporter:
              Chandra Shekhar Pandey
              Votes:
              1 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved: