java.lang.IndexOutOfBoundsException

If you like a tip written by other Samebug users, mark is as helpful! Marks help our algorithm provide you better solutions and also help other users.
tip

Thrown to indicate that an index of some sort (such as to an array, to a string, or to a vector) is out of range. Applications can subclass this class to indicate similar exceptions.


rafael

You have a different solution? A short tip here would help you and many other users who saw this issue last week.

  • getReference() exception
    via by Dola Woolfe,
  • getReference() exception
    via by Dola Woolfe,
  • I noticed when running nexus.bat, the following error is logged. Please let me know if I need to attach my nexus.xml for review. 2008-09-04 23:32:28.234 ERROR [WrapperListener_start_runner:] - org.sonatype.nexus.index.IndexerManager:default: Could not maintain indexing contexts! java.lang.IndexOutOfBoundsException: Index: 8, Size: 2 at java.util.ArrayList.RangeCheck(ArrayList.java:547) at java.util.ArrayList.get(ArrayList.java:322) at org.apache.lucene.index.FieldInfos.fieldInfo(FieldInfos.java:260) at org.apache.lucene.index.FieldInfos.fieldName(FieldInfos.java:249) at org.apache.lucene.index.TermBuffer.read(TermBuffer.java:68) at org.apache.lucene.index.SegmentTermEnum.next(SegmentTermEnum.java:123) at org.apache.lucene.index.TermInfosReader.ensureIndexIsRead(TermInfosReader.java:159) at org.apache.lucene.index.TermInfosReader.get(TermInfosReader.java:202) at org.apache.lucene.index.SegmentTermDocs.seek(SegmentTermDocs.java:54) at org.apache.lucene.index.IndexReader.termDocs(IndexReader.java:668) at org.apache.lucene.index.IndexReader.deleteDocuments(IndexReader.java:756) at org.apache.lucene.index.IndexWriter.applyDeletes(IndexWriter.java:3512) at org.apache.lucene.index.IndexWriter.applyDeletes(IndexWriter.java:3445) at org.apache.lucene.index.IndexWriter.doFlush(IndexWriter.java:2638) at org.apache.lucene.index.IndexWriter.flush(IndexWriter.java:2523) at org.apache.lucene.index.IndexWriter.flush(IndexWriter.java:2509) at org.sonatype.nexus.index.context.DefaultIndexingContext.storeDescriptor(DefaultIndexingContext.java:269) at org.sonatype.nexus.index.context.DefaultIndexingContext.checkAndUpdateIndexDescriptor(DefaultIndexingContext.java:211) at org.sonatype.nexus.index.context.DefaultIndexingContext.prepareIndex(DefaultIndexingContext.java:179) at org.sonatype.nexus.index.context.DefaultIndexingContext.<init>(DefaultIndexingContext.java:137) at org.sonatype.nexus.index.DefaultNexusIndexer.addIndexingContextForced(DefaultNexusIndexer.java:121) at org.sonatype.nexus.index.DefaultIndexerManager.addRepositoryIndexContext(DefaultIndexerManager.java:239) at org.sonatype.nexus.index.DefaultIndexerManager.onProximityEvent(DefaultIndexerManager.java:1304) at org.sonatype.nexus.proxy.EventMulticasterComponent.notifyProximityEventListeners(EventMulticasterComponent.java:65) at org.sonatype.nexus.proxy.registry.DefaultRepositoryRegistry.insertRepository(DefaultRepositoryRegistry.java:88) at org.sonatype.nexus.proxy.registry.DefaultRepositoryRegistry.addRepository(DefaultRepositoryRegistry.java:98) at org.sonatype.nexus.configuration.application.DefaultNexusConfiguration.createRepositories(DefaultNexusConfiguration.java:463) at org.sonatype.nexus.configuration.application.DefaultNexusConfiguration.createInternals(DefaultNexusConfiguration.java:441) at org.sonatype.nexus.DefaultNexus.start(DefaultNexus.java:1451) at org.codehaus.plexus.personality.plexus.lifecycle.phase.StartPhase.execute(StartPhase.java:33) at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.startComponentLifecycle(XBeanComponentBuilder.java:219) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.build(XBeanComponentBuilder.java:97) at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:135) at org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96) at org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147) at org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:69) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:432) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:426) at org.sonatype.nexus.web.NexusBooterListener.contextInitialized(NexusBooterListener.java:39) at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543) at org.mortbay.jetty.servlet.Context.startContext(Context.java:136) at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220) at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513) at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:152) at org.mortbay.jetty.handler.ContextHandlerCollection.doStart(ContextHandlerCollection.java:156) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:152) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130) at org.mortbay.jetty.Server.doStart(Server.java:222) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.sonatype.plexus.jetty.DefaultServletContainer.start(DefaultServletContainer.java:250) at org.codehaus.plexus.personality.plexus.lifecycle.phase.StartPhase.execute(StartPhase.java:33) at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.startComponentLifecycle(XBeanComponentBuilder.java:219) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.build(XBeanComponentBuilder.java:97) at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:135) at org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96) at org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:486) at org.codehaus.plexus.container.initialization.StartLoadOnStartComponentsPhase.execute(StartLoadOnStartComponentsPhase.java:69) at org.codehaus.plexus.DefaultPlexusContainer.initializePhases(DefaultPlexusContainer.java:851) at org.codehaus.plexus.DefaultPlexusContainer.initialize(DefaultPlexusContainer.java:815) at org.codehaus.plexus.DefaultPlexusContainer.construct(DefaultPlexusContainer.java:407) at org.codehaus.plexus.DefaultPlexusContainer.<init>(DefaultPlexusContainer.java:198) at org.sonatype.appbooter.PlexusContainerHost.startContainer(PlexusContainerHost.java:221) at org.sonatype.appbooter.jsw.PlexusJSWListener.start(PlexusJSWListener.java:101) at org.tanukisoftware.wrapper.WrapperManager$12.run(WrapperManager.java:2788)
    via by Kristine O'Connor,
  • I noticed when running nexus.bat, the following error is logged. Please let me know if I need to attach my nexus.xml for review. 2008-09-04 23:32:28.234 ERROR [WrapperListener_start_runner:] - org.sonatype.nexus.index.IndexerManager:default: Could not maintain indexing contexts! java.lang.IndexOutOfBoundsException: Index: 8, Size: 2 at java.util.ArrayList.RangeCheck(ArrayList.java:547) at java.util.ArrayList.get(ArrayList.java:322) at org.apache.lucene.index.FieldInfos.fieldInfo(FieldInfos.java:260) at org.apache.lucene.index.FieldInfos.fieldName(FieldInfos.java:249) at org.apache.lucene.index.TermBuffer.read(TermBuffer.java:68) at org.apache.lucene.index.SegmentTermEnum.next(SegmentTermEnum.java:123) at org.apache.lucene.index.TermInfosReader.ensureIndexIsRead(TermInfosReader.java:159) at org.apache.lucene.index.TermInfosReader.get(TermInfosReader.java:202) at org.apache.lucene.index.SegmentTermDocs.seek(SegmentTermDocs.java:54) at org.apache.lucene.index.IndexReader.termDocs(IndexReader.java:668) at org.apache.lucene.index.IndexReader.deleteDocuments(IndexReader.java:756) at org.apache.lucene.index.IndexWriter.applyDeletes(IndexWriter.java:3512) at org.apache.lucene.index.IndexWriter.applyDeletes(IndexWriter.java:3445) at org.apache.lucene.index.IndexWriter.doFlush(IndexWriter.java:2638) at org.apache.lucene.index.IndexWriter.flush(IndexWriter.java:2523) at org.apache.lucene.index.IndexWriter.flush(IndexWriter.java:2509) at org.sonatype.nexus.index.context.DefaultIndexingContext.storeDescriptor(DefaultIndexingContext.java:269) at org.sonatype.nexus.index.context.DefaultIndexingContext.checkAndUpdateIndexDescriptor(DefaultIndexingContext.java:211) at org.sonatype.nexus.index.context.DefaultIndexingContext.prepareIndex(DefaultIndexingContext.java:179) at org.sonatype.nexus.index.context.DefaultIndexingContext.<init>(DefaultIndexingContext.java:137) at org.sonatype.nexus.index.DefaultNexusIndexer.addIndexingContextForced(DefaultNexusIndexer.java:121) at org.sonatype.nexus.index.DefaultIndexerManager.addRepositoryIndexContext(DefaultIndexerManager.java:239) at org.sonatype.nexus.index.DefaultIndexerManager.onProximityEvent(DefaultIndexerManager.java:1304) at org.sonatype.nexus.proxy.EventMulticasterComponent.notifyProximityEventListeners(EventMulticasterComponent.java:65) at org.sonatype.nexus.proxy.registry.DefaultRepositoryRegistry.insertRepository(DefaultRepositoryRegistry.java:88) at org.sonatype.nexus.proxy.registry.DefaultRepositoryRegistry.addRepository(DefaultRepositoryRegistry.java:98) at org.sonatype.nexus.configuration.application.DefaultNexusConfiguration.createRepositories(DefaultNexusConfiguration.java:463) at org.sonatype.nexus.configuration.application.DefaultNexusConfiguration.createInternals(DefaultNexusConfiguration.java:441) at org.sonatype.nexus.DefaultNexus.start(DefaultNexus.java:1451) at org.codehaus.plexus.personality.plexus.lifecycle.phase.StartPhase.execute(StartPhase.java:33) at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.startComponentLifecycle(XBeanComponentBuilder.java:219) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.build(XBeanComponentBuilder.java:97) at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:135) at org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96) at org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147) at org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:69) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:432) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:426) at org.sonatype.nexus.web.NexusBooterListener.contextInitialized(NexusBooterListener.java:39) at org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:543) at org.mortbay.jetty.servlet.Context.startContext(Context.java:136) at org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1220) at org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:513) at org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:448) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:152) at org.mortbay.jetty.handler.ContextHandlerCollection.doStart(ContextHandlerCollection.java:156) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.mortbay.jetty.handler.HandlerCollection.doStart(HandlerCollection.java:152) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130) at org.mortbay.jetty.Server.doStart(Server.java:222) at org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:39) at org.sonatype.plexus.jetty.DefaultServletContainer.start(DefaultServletContainer.java:250) at org.codehaus.plexus.personality.plexus.lifecycle.phase.StartPhase.execute(StartPhase.java:33) at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:97) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.startComponentLifecycle(XBeanComponentBuilder.java:219) at org.codehaus.plexus.component.builder.XBeanComponentBuilder.build(XBeanComponentBuilder.java:97) at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:135) at org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:96) at org.codehaus.plexus.DefaultComponentLookupManager.lookup(DefaultComponentLookupManager.java:147) at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:486) at org.codehaus.plexus.container.initialization.StartLoadOnStartComponentsPhase.execute(StartLoadOnStartComponentsPhase.java:69) at org.codehaus.plexus.DefaultPlexusContainer.initializePhases(DefaultPlexusContainer.java:851) at org.codehaus.plexus.DefaultPlexusContainer.initialize(DefaultPlexusContainer.java:815) at org.codehaus.plexus.DefaultPlexusContainer.construct(DefaultPlexusContainer.java:407) at org.codehaus.plexus.DefaultPlexusContainer.<init>(DefaultPlexusContainer.java:198) at org.sonatype.appbooter.PlexusContainerHost.startContainer(PlexusContainerHost.java:221) at org.sonatype.appbooter.jsw.PlexusJSWListener.start(PlexusJSWListener.java:101) at org.tanukisoftware.wrapper.WrapperManager$12.run(WrapperManager.java:2788)
    via by Kristine O'Connor,
  • IOOBE after JsonObject.remove
    via GitHub by ralfstx
    ,
  • Jsoup :eq(n) selector
    via Stack Overflow by wangjbao
    ,
  • How to ignore casing of element names in JaxB
    via Stack Overflow by tkr
    ,
    • java.lang.IndexOutOfBoundsException: Index: 8, Size: 2 at java.util.ArrayList.RangeCheck(ArrayList.java:546) at java.util.ArrayList.get(ArrayList.java:321) at org.apache.poi.hssf.model.Workbook.getSheetName(Workbook.java:503) at org.apache.poi.hssf.model.Workbook.findSheetNameFromExternSheet(Workbook.java:1778) at org.apache.poi.hssf.model.Workbook.getSheetReferences(Workbook.java:1761) at org.apache.poi.hssf.record.formula.Ref3DPtg.toFormulaString(Ref3DPtg.java:160) at org.apache.poi.hssf.record.NameRecord.getAreaReference(NameRecord.java:677) at org.apache.poi.hssf.usermodel.HSSFName.getReference(HSSFName.java:87) at contrib.justin.OpenAndReadPA.jgbGetNamedValue(OpenAndReadPA.java:233)

    Users with the same issue

    Unknown visitor1 times, last one,
    Pilleo
    9 times, last one,
    Agócs Tamás
    8 times, last one,
    aidoan
    2 times, last one,
    Unknown visitor1 times, last one,
    225 more bugmates