Email Handler for Gmail does not process all Email Requests
Platform Notice: Data Center Only - This article only applies to Atlassian products on the Data Center platform.
Note that this KB was created for the Data Center version of the product. Data Center KBs for non-Data-Center-specific features may also work for Server versions of the product, however they have not been tested. Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.
*Except Fisheye and Crucible
Summary
Some emails are coming in but are not being processed into tickets.
Environment
Gmail Email Server
Diagnosis
The Too many simultaneous connections via protocol imaps
error shows up in the mail logs.
There is a significant number of mail handlers all connecting to one Gmail account.
The error means that the mail host (gmail in this case) is limiting the number of concurrent connections from any single source.
Cause
The error means that the mail host (gmail in this case) is limiting the number of concurrent connections from any single source.
According to Google documentation, the maximum number of simultaneous connections to a gmail mailbox is 15.
You can only use 15 IMAP connections per account. If you have many email clients getting messages from Gmail at the same time, you may see the "Too many simultaneous connections" error.
Solution
Possible Solutions
Increase Mail Handler Delay
A mail handler has a delay setting which dictates how often it will poll the mail server for new messages. Increasing this delay can help to reduce the number of connections that Jira makes to Gmail. You can edit this setting in the mail handlers configuration.
In previous instances of this error, setting the delay to 5 or more minutes has helped to reduce the number of simultaneous connections to the mail service.
Larger intervals
Space the mail handlers further apart to reduce the possibility of mail handlers running at the same interval. This won't have a guarantee to fix the issue, but it would lessen the occurrence of this error.
Split emails into two or more accounts
The limit that Gmail imposes on IMAP connections is set per account.
A possible workaround is to setup separate email addresses for some of the mail handlers. In effect it would have lesser mail handlers competing for the IMAP connection limit.
This way, the mail handlers that are working on a different gmail account won't count against the 15 IMAP connection limit of the other set of mail handlers.
Switch some of the mail handlers to POP
These errors are due to IMAP connection limits. If some of the other mail handlers are switched to POP protocol, they won't count towards the 15 IMAP connection limit.
Please do note that Gmail POP has its own set of limits as well. The Gmail documentation says that POP clients accessing Gmail account too frequently may run into problems too, but there seems to be no exact number mentioned.
If you see the "Account exceeded POP command or bandwidth limits error," it's usually because your POP clients have been accessing your Gmail account too frequently.
To fix this, change your client's settings so it won't check for new messages too frequently.
Was this helpful?