Incoming mail not deleted

Pierre Naude February 6, 2013

We are in the process of updating our JIRA installation to 5.2.5 and would like to use the incoming mail feature.

So far we have configured the incoming IMAP mail server, and the test completes successfully. Next, we configure a mail handler to pick up mail from a specific IMAP folder. This also works, it picks up the mail, and it creates an issue as expected.

This is where the real problem comes in. JIRA says that it is deleting the processed mail, but it still shows after the issue has been created. During the next run, the issue will be created for a second time, 3rd and 4th and so on until the mail is manually deleted. We are using Google Apps, so our mail is hosted by Google. The problem does not occur when using POP, but we need IMAP for folder support.

So far I have tried various IMAP settings in Google to see if it makes a difference, but it does not. If we point an ordinary mail client to the mail account, deletions work 100%.

Any ideas?

2 answers

0 votes
Alejandro Conde Carrillo
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
February 17, 2013

Unfortunately this is caused by the way Gmail implements the <tt>delete</tt> command and cannot be fixed on JIRA side. When Gmail receives a <tt>delete</tt> command, it only removes the inbox tag but it does not actually delete the message, as stated in Gmail documentation:

Messages that are deleted from an IMAP folder (except for those in [Gmail]/Spam or [Gmail]/Trash) only have that label removed and still exist in All Mail.

Pierre Naude March 4, 2013

Hi Alex,

I don't doubt your comment with regards the the way deletions are handled. That is not the issue here.

In mail clients like Thunderbird the original folder label is removed and the mail moves to All Mail as stated.

The problem with Jira is that the original label is not removed, leaving the mail in the folder it was filtered to and causing Jira to endlessly process the mail. If it only moved to All Mail that would be perfect, but it remains in the original folder...

Tsol
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 6, 2013

Hi,

i'm experimenting with issue creation from email. We use Google apps too. The default setting in Gmail is what Alex describes in his answer.

Have tried the Immediately delete the message forever option in IMAP access under the Forwarding and POP/IMAP tab?

Cheers

0 votes
Willi Schöpke February 10, 2013

We use JIRA installation 5.2.4 in the organisation and have the same problem. It seem that the problem is not only our problem.

We use IMAP as protocol. After a short time (one day and ca. 2900 issues/mails) the mailserver blocked the mail query user.

A quick answer would like me happy

Suggest an answer

Log in or Sign up to answer