Details
-
Bug
-
Resolution: Unresolved
-
Low
-
None
-
6.2.4, 7.2.3
-
6.02
-
10
-
Severity 3 - Minor
-
1
-
Description
Summary:
How mail handler normally works:
- detect the email in the inbox
- create issue
- if it detects attachment, it will try to add the attachment to the issue
- once the attachment was successfully added, delete the email from inbox
How it works here (happens occasionally):
When the attachment was not added successfully, the same email stays in the inbox. This cause the mail handler to re-process the email and re-create an issue again out of it
Steps to reproduce:
This is not reproducible.
Error causing the email not being deleted (failed to add the attachment):
2014-12-11 19:58:57,489 QuartzScheduler_Worker-3 DEBUG ServiceRunner XX.YYYY [mail.incoming.CreateOrCommentHandler.3] Checking if attachment should be added to issue: 2014-12-11 19:58:57,489 QuartzScheduler_Worker-3 DEBUG ServiceRunner XX.YYYY [mail.incoming.CreateOrCommentHandler.3] Content-Type: image/png; name="XYXY.png" 2014-12-11 19:58:57,490 QuartzScheduler_Worker-3 DEBUG ServiceRunner XX.YYYY [mail.incoming.CreateOrCommentHandler.3] Content-Disposition: attachment 2014-12-11 19:58:57,491 QuartzScheduler_Worker-3 ERROR ServiceRunner XX.YYYY [atlassian.mail.incoming.mailfetcherservice] XX.YYYY[XYXYX]: Exception: null java.lang.NegativeArraySizeException at com.sun.imageio.plugins.png.PNGImageReader.readMetadata(Unknown Source) at com.sun.imageio.plugins.png.PNGImageReader.getImageMetadata(Unknown Source) at com.atlassian.jira.plugins.mail.handlers.GeneratedAttachmentRecogniser.containsJiraMetadata(GeneratedAttachmentRecogniser.java:64) at com.atlassian.jira.plugins.mail.handlers.GeneratedAttachmentRecogniser.<init>(GeneratedAttachmentRecogniser.java:32) at
Suggestion
If deleting the unsuccessfully processed email is not an option (perhaps for integrity reason), then maybe mail handler could mark it as read and notify the reporter to resend an email for creating issue (while the read email will not be processed anymore).