java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false

Sonatype JIRA | Pat Podenski | 7 years ago
  1. 0

    The following stack trace results from a scheduled task which is supposed to index the Public Repositories Group. ---------------------------------------------------------------------------------- Task Name: publish public repo index Stack trace: java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false at org.apache.lucene.index.IndexWriter.abort(IndexWriter.java:2009) at org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1175) at org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1154) at org.sonatype.nexus.index.context.NexusIndexWriter.close(NexusIndexWriter.java:48) at org.sonatype.nexus.index.context.DefaultIndexingContext.closeReaders(DefaultIndexingContext.java:637) at org.sonatype.nexus.index.context.DefaultIndexingContext.merge(DefaultIndexingContext.java:609) at org.sonatype.nexus.index.context.DefaultIndexingContext.merge(DefaultIndexingContext.java:545) at org.sonatype.nexus.index.DefaultIndexerManager.mergeContexts(DefaultIndexerManager.java:353) at org.sonatype.nexus.index.DefaultIndexerManager.publishRepositoryIndex(DefaultIndexerManager.java:1195) at org.sonatype.nexus.index.DefaultIndexerManager.publishRepositoryGroupIndex(DefaultIndexerManager.java:1162) at org.sonatype.nexus.index.ProxyIndexerManager.publishRepositoryGroupIndex(ProxyIndexerManager.java:173) at org.sonatype.nexus.tasks.PublishIndexesTask.doRun(PublishIndexesTask.java:50) at org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:192) at org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:338) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269) at java.util.concurrent.FutureTask.run(FutureTask.java:123) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:65) at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:172) at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:651) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:676) at java.lang.Thread.run(Thread.java:613) ----------------------------------------------------------------------------------

    Sonatype JIRA | 7 years ago | Pat Podenski
    java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false
  2. 0

    I enabled remote index downloads for 'central' (stock nexus.xml) task was created, but reindex failed jvm 1 | 2009-08-11 15:46:00 WARN - o.s.n.i.ComposableI~:lucene - Cannot fetch remote index for repository central jvm 1 | java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false jvm 1 | at org.apache.lucene.index.IndexWriter.abort(IndexWriter.java:2009) jvm 1 | at org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1175) jvm 1 | at org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1154) jvm 1 | at org.sonatype.nexus.index.context.NexusIndexWriter.close(NexusIndexWriter.java:48) jvm 1 | at org.sonatype.nexus.index.context.IndexUtils.close(IndexUtils.java:371) jvm 1 | at org.sonatype.nexus.index.updater.DefaultIndexUpdater.unpackIndexData(DefaultIndexUpdater.java:520) jvm 1 | at org.sonatype.nexus.index.updater.DefaultIndexUpdater.loadIndexDirectory(DefaultIndexUpdater.java:220) jvm 1 | at org.sonatype.nexus.index.updater.DefaultIndexUpdater.fetchAndUpdateIndex(DefaultIndexUpdater.java:135) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.updateRemoteIndex(DefaultIndexerManager.java:846) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.updateIndexForRemoteRepository(DefaultIndexerManager.java:716) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.downloadRepositoryIndex(DefaultIndexerManager.java:691) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:580) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:503) jvm 1 | at org.sonatype.nexus.index.ProxyIndexerManager.reindexRepository(ProxyIndexerManager.java:200) jvm 1 | at org.sonatype.nexus.tasks.ReindexTask.doRun(ReindexTask.java:54) jvm 1 | at org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:181) jvm 1 | at org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:339) jvm 1 | at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) jvm 1 | at java.util.concurrent.FutureTask.run(FutureTask.java:138) jvm 1 | at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98) jvm 1 | at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:207) jvm 1 | at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) jvm 1 | at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) jvm 1 | at java.lang.Thread.run(Thread.java:637) jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.i.ComposableI~:lucene - Cascading merge of group indexes for group 'public', where repository 'central' is member. jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.i.ComposableI~:lucene - Publishing best index for repository central jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.i.p.IndexPack~:default - Unable to read properties file, will force index regeneration jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.f.FeedRecorder:default - Reindexing repository Maven Central from path / and below. : Process started on Tue Aug 11 15:43:18 EDT 2009, finished successfully on Tue Aug 11 15:46:01 EDT 2009

    Sonatype JIRA | 7 years ago | Brian Demers
    java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false
  3. 0

    I enabled remote index downloads for 'central' (stock nexus.xml) task was created, but reindex failed jvm 1 | 2009-08-11 15:46:00 WARN - o.s.n.i.ComposableI~:lucene - Cannot fetch remote index for repository central jvm 1 | java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false jvm 1 | at org.apache.lucene.index.IndexWriter.abort(IndexWriter.java:2009) jvm 1 | at org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1175) jvm 1 | at org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1154) jvm 1 | at org.sonatype.nexus.index.context.NexusIndexWriter.close(NexusIndexWriter.java:48) jvm 1 | at org.sonatype.nexus.index.context.IndexUtils.close(IndexUtils.java:371) jvm 1 | at org.sonatype.nexus.index.updater.DefaultIndexUpdater.unpackIndexData(DefaultIndexUpdater.java:520) jvm 1 | at org.sonatype.nexus.index.updater.DefaultIndexUpdater.loadIndexDirectory(DefaultIndexUpdater.java:220) jvm 1 | at org.sonatype.nexus.index.updater.DefaultIndexUpdater.fetchAndUpdateIndex(DefaultIndexUpdater.java:135) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.updateRemoteIndex(DefaultIndexerManager.java:846) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.updateIndexForRemoteRepository(DefaultIndexerManager.java:716) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.downloadRepositoryIndex(DefaultIndexerManager.java:691) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:580) jvm 1 | at org.sonatype.nexus.index.DefaultIndexerManager.reindexRepository(DefaultIndexerManager.java:503) jvm 1 | at org.sonatype.nexus.index.ProxyIndexerManager.reindexRepository(ProxyIndexerManager.java:200) jvm 1 | at org.sonatype.nexus.tasks.ReindexTask.doRun(ReindexTask.java:54) jvm 1 | at org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:181) jvm 1 | at org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:339) jvm 1 | at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) jvm 1 | at java.util.concurrent.FutureTask.run(FutureTask.java:138) jvm 1 | at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:98) jvm 1 | at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:207) jvm 1 | at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) jvm 1 | at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) jvm 1 | at java.lang.Thread.run(Thread.java:637) jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.i.ComposableI~:lucene - Cascading merge of group indexes for group 'public', where repository 'central' is member. jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.i.ComposableI~:lucene - Publishing best index for repository central jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.i.p.IndexPack~:default - Unable to read properties file, will force index regeneration jvm 1 | 2009-08-11 15:46:01 INFO - o.s.n.f.FeedRecorder:default - Reindexing repository Maven Central from path / and below. : Process started on Tue Aug 11 15:43:18 EDT 2009, finished successfully on Tue Aug 11 15:46:01 EDT 2009

    Sonatype JIRA | 7 years ago | Brian Demers
    java.lang.IllegalStateException: abort() can only be called when IndexWriter was opened with autoCommit=false
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0
  6. 0

    Not finding the right solution?
    Take a tour to get the most out of Samebug.

    Tired of useless tips?

    Automated exception search integrated into your IDE

    Root Cause Analysis

    1. java.lang.IllegalStateException

      abort() can only be called when IndexWriter was opened with autoCommit=false

      at org.apache.lucene.index.IndexWriter.abort()
    2. Lucene
      IndexWriter.close
      1. org.apache.lucene.index.IndexWriter.abort(IndexWriter.java:2009)
      2. org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1175)
      3. org.apache.lucene.index.IndexWriter.close(IndexWriter.java:1154)
      3 frames
    3. Sonatype Nexus Indexer
      ProxyIndexerManager.publishRepositoryGroupIndex
      1. org.sonatype.nexus.index.context.NexusIndexWriter.close(NexusIndexWriter.java:48)
      2. org.sonatype.nexus.index.context.DefaultIndexingContext.closeReaders(DefaultIndexingContext.java:637)
      3. org.sonatype.nexus.index.context.DefaultIndexingContext.merge(DefaultIndexingContext.java:609)
      4. org.sonatype.nexus.index.context.DefaultIndexingContext.merge(DefaultIndexingContext.java:545)
      5. org.sonatype.nexus.index.DefaultIndexerManager.mergeContexts(DefaultIndexerManager.java:353)
      6. org.sonatype.nexus.index.DefaultIndexerManager.publishRepositoryIndex(DefaultIndexerManager.java:1195)
      7. org.sonatype.nexus.index.DefaultIndexerManager.publishRepositoryGroupIndex(DefaultIndexerManager.java:1162)
      8. org.sonatype.nexus.index.ProxyIndexerManager.publishRepositoryGroupIndex(ProxyIndexerManager.java:173)
      8 frames
    4. ${project.groupId}:${project.artifactId}
      AbstractNexusTask.call
      1. org.sonatype.nexus.tasks.PublishIndexesTask.doRun(PublishIndexesTask.java:50)
      2. org.sonatype.nexus.scheduling.AbstractNexusTask.call(AbstractNexusTask.java:192)
      2 frames
    5. ${project.groupId}:${project.artifactId}
      DefaultScheduledTask.call
      1. org.sonatype.scheduling.DefaultScheduledTask.call(DefaultScheduledTask.java:338)
      1 frame
    6. Java RT
      Thread.run
      1. java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:269)
      2. java.util.concurrent.FutureTask.run(FutureTask.java:123)
      3. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$301(ScheduledThreadPoolExecutor.java:65)
      4. java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:172)
      5. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:651)
      6. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:676)
      7. java.lang.Thread.run(Thread.java:613)
      7 frames