java.lang.ArrayIndexOutOfBoundsException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • Direct access of the Mail Server in JEMH for forwarding hints has been found to run into the following. JEMH should probably put such notifications through the JIRA mail queue to get the resilience that even the in-memory queue offers, to reduce these kinds of occurrences. {noformat} ArrayIndexOutOfBoundsException: message number (6) out of bounds (2): java.lang.ArrayIndexOutOfBoundsException: message number (6) out of bounds (2) at com.sun.mail.imap.MessageCache.getMessage(MessageCache.java:132) at com.sun.mail.imap.MessageCache.getMessageBySeqnum(MessageCache.java:162) at com.sun.mail.imap.IMAPFolder.getMessageBySeqNumber(IMAPFolder.java:2809) at com.sun.mail.imap.IMAPFolder.handleResponse(IMAPFolder.java:2486) at com.sun.mail.iap.Protocol.notifyResponseHandlers(Protocol.java:216) at com.sun.mail.imap.protocol.IMAPProtocol.fetchBody(IMAPProtocol.java:1319) at com.sun.mail.imap.protocol.IMAPProtocol.fetchBody(IMAPProtocol.java:1306) at com.sun.mail.imap.IMAPInputStream.fill(IMAPInputStream.java:148) at com.sun.mail.imap.IMAPInputStream.read(IMAPInputStream.java:208) at com.sun.mail.imap.IMAPInputStream.read(IMAPInputStream.java:234) at com.sun.mail.imap.IMAPMessage.writeTo(IMAPMessage.java:721) at com.javahollic.jira.emh.service.DefaultJEMHMessageManager.sendForwardEmail(DefaultJEMHMessageManager.java:750) at com.javahollic.jira.emh.service.EnterpriseMessageHandlerImpl.handleException(EnterpriseMessageHandlerImpl.java:569) at com.javahollic.jira.emh.service.EnterpriseMessageHandlerImpl.handleMessage(EnterpriseMessageHandlerImpl.java:383) at com.javahollic.jira.emh.service.EnterpriseMessageHandlerProxy.handleMessage(EnterpriseMessageHandlerProxy.java:48) at com.atlassian.jira.service.services.mail.MailFetcherService$1.process(MailFetcherService.java:438) at com.atlassian.jira.service.services.mail.MailFetcherService$MessageProviderImpl.getAndProcessMail(MailFetcherService.java:304) at com.atlassian.jira.service.services.mail.MailFetcherService.runImpl(MailFetcherService.java:426) at com.atlassian.jira.service.services.file.AbstractMessageHandlingService.run(AbstractMessageHandlingService.java:263) {noformat} I googled, found [this entry|https://community.oracle.com/thread/2491711] that refers to Exchange (is that what you are using?) the entry links to [this|http://kenai.com/projects/javamail/pages/Exchange]. No specific resolution. JEMH can't do anything specifically here as its within the javamail library. This [message|https://java.net/projects/javamail/lists/issues/archive/2010-09/message/1] indicates that some 'improvements' in javamail went in to javamail-1.4.4 JIRA 7 ships with javamail 1.4.5, so that would hopefully work.
    via by Anfield Leung,
  • ArrayIndexOutOfBoundsException on reading mailbox message
    via by db5459f6-7799-4209-bafe-b44400fbfd38,
  • Direct access of the Mail Server in JEMH for forwarding hints has been found to run into the following. JEMH should probably put such notifications through the JIRA mail queue to get the resilience that even the in-memory queue offers, to reduce these kinds of occurrences. {noformat} ArrayIndexOutOfBoundsException: message number (6) out of bounds (2): java.lang.ArrayIndexOutOfBoundsException: message number (6) out of bounds (2) at com.sun.mail.imap.MessageCache.getMessage(MessageCache.java:132) at com.sun.mail.imap.MessageCache.getMessageBySeqnum(MessageCache.java:162) at com.sun.mail.imap.IMAPFolder.getMessageBySeqNumber(IMAPFolder.java:2809) at com.sun.mail.imap.IMAPFolder.handleResponse(IMAPFolder.java:2486) at com.sun.mail.iap.Protocol.notifyResponseHandlers(Protocol.java:216) at com.sun.mail.imap.protocol.IMAPProtocol.fetchBody(IMAPProtocol.java:1319) at com.sun.mail.imap.protocol.IMAPProtocol.fetchBody(IMAPProtocol.java:1306) at com.sun.mail.imap.IMAPInputStream.fill(IMAPInputStream.java:148) at com.sun.mail.imap.IMAPInputStream.read(IMAPInputStream.java:208) at com.sun.mail.imap.IMAPInputStream.read(IMAPInputStream.java:234) at com.sun.mail.imap.IMAPMessage.writeTo(IMAPMessage.java:721) at com.javahollic.jira.emh.service.DefaultJEMHMessageManager.sendForwardEmail(DefaultJEMHMessageManager.java:750) at com.javahollic.jira.emh.service.EnterpriseMessageHandlerImpl.handleException(EnterpriseMessageHandlerImpl.java:569) at com.javahollic.jira.emh.service.EnterpriseMessageHandlerImpl.handleMessage(EnterpriseMessageHandlerImpl.java:383) at com.javahollic.jira.emh.service.EnterpriseMessageHandlerProxy.handleMessage(EnterpriseMessageHandlerProxy.java:48) at com.atlassian.jira.service.services.mail.MailFetcherService$1.process(MailFetcherService.java:438) at com.atlassian.jira.service.services.mail.MailFetcherService$MessageProviderImpl.getAndProcessMail(MailFetcherService.java:304) at com.atlassian.jira.service.services.mail.MailFetcherService.runImpl(MailFetcherService.java:426) at com.atlassian.jira.service.services.file.AbstractMessageHandlingService.run(AbstractMessageHandlingService.java:263) {noformat} I googled, found [this entry|https://community.oracle.com/thread/2491711] that refers to Exchange (is that what you are using?) the entry links to [this|http://kenai.com/projects/javamail/pages/Exchange]. No specific resolution. JEMH can't do anything specifically here as its within the javamail library. This [message|https://java.net/projects/javamail/lists/issues/archive/2010-09/message/1] indicates that some 'improvements' in javamail went in to javamail-1.4.4 JIRA 7 ships with javamail 1.4.5, so that would hopefully work.
    via by Anfield Leung,
    • java.lang.ArrayIndexOutOfBoundsException: message number (7) out of bounds (6) at com.sun.mail.imap.MessageCache.getMessage(MessageCache.java:135) at com.sun.mail.imap.MessageCache.getMessageBySeqnum(MessageCache.java:164) at com.sun.mail.imap.IMAPFolder.getMessageBySeqNumber(IMAPFolder.java:3005) at com.sun.mail.imap.IMAPFolder.search(IMAPFolder.java:1863) at org.springframework.integration.mail.ImapMailReceiver.searchForNewMessages(ImapMailReceiver.java:202) at org.springframework.integration.mail.ImapMailReceiver.waitForNewMessages(ImapMailReceiver.java:167) at org.springframework.integration.mail.ImapIdleChannelAdapter$IdleTask.run(ImapIdleChannelAdapter.java:220) at org.springframework.integration.mail.ImapIdleChannelAdapter$ReceivingTask.run(ImapIdleChannelAdapter.java:190) at org.springframework.scheduling.support.DelegatingErrorHandlingRunnable.run(DelegatingErrorHandlingRunnable.java:54) at org.springframework.scheduling.concurrent.ReschedulingRunnable.run(ReschedulingRunnable.java:81) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$201(ScheduledThreadPoolExecutor.java:180) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:293) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745)
    No Bugmate found.