org.apache.lucene.store.AlreadyClosedException: this IndexReader is closed

Sonatype JIRA | Rich Seddon | 5 years ago
tip
Your exception is missing from the Samebug knowledge base.
Here are the best solutions we found on the Internet.
Click on the to mark the helpful solution and get rewards for you help.
  1. 0

    Looks like we've still got a race condition in the index, got a report of this exception occurring in 2.0.3. 2012-04-19 10:21:39 ERROR [ost-1-thread-41] - org.sonatype.nexus.events.IndexerManagerEventInspector - Could not maintain index! org.apache.lucene.store.AlreadyClosedException: this IndexReader is closed at org.apache.lucene.index.IndexReader.ensureOpen(IndexReader.java:177) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.index.IndexReader.termDocs(IndexReader.java:812) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.index.SegmentReader.termDocs(SegmentReader.java:956) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.search.TermQuery$TermWeight.scorer(TermQuery.java:74) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:210) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:170) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.search.Searcher.search(Searcher.java:98) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.lucene.search.Searcher.search(Searcher.java:108) ~[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19] at org.apache.maven.index.DefaultIndexerEngine.getOldDocument(DefaultIndexerEngine.java:158) ~[indexer-core-4.1.3-SONATYPE.jar:4.1.3-SONATYPE] at org.apache.maven.index.DefaultIndexerEngine.update(DefaultIndexerEngine.java:77) ~[indexer-core-4.1.3-SONATYPE.jar:4.1.3-SONATYPE] at org.apache.maven.index.DefaultNexusIndexer.addArtifactToIndex(DefaultNexusIndexer.java:371) ~[indexer-core-4.1.3-SONATYPE.jar:4.1.3-SONATYPE] at org.sonatype.nexus.index.DefaultIndexerManager.addItemToIndex(DefaultIndexerManager.java:655) ~[nexus-indexer-lucene-plugin-2.0.3.jar:na] at org.sonatype.nexus.events.IndexerManagerEventInspector.inspectForIndexerManager(IndexerManagerEventInspector.java:75) [nexus-indexer-lucene-plugin-2.0.3.jar:na] at org.sonatype.nexus.events.IndexerManagerEventInspector.inspect(IndexerManagerEventInspector.java:60) [nexus-indexer-lucene-plugin-2.0.3.jar:na] at org.sonatype.nexus.events.DefaultEventInspectorHost$EventInspectorHandler.run(DefaultEventInspectorHost.java:184) [nexus-app-2.0.3.jar:na] at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886) [na:1.6.0_27] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908) [na:1.6.0_27] at java.lang.Thread.run(Thread.java:662) [na:1.6.0_27]

    Sonatype JIRA | 5 years ago | Rich Seddon
    org.apache.lucene.store.AlreadyClosedException: this IndexReader is closed
  2. 0

    Program crashes on closing

    docfetcher | 3 years ago | *anonymous
    org.apache.lucene.store.AlreadyClosedException: this IndexReader is closed
  3. 0

    AlreadyClosedException

    docfetcher | 3 years ago | *anonymous
    org.apache.lucene.store.AlreadyClosedException: this IndexReader is closed
  4. Speed up your debug routine!

    Automated exception search integrated into your IDE

  5. 0

    Stacktrace 11_29_2016

    docfetcher | 5 months ago | *anonymous
    org.apache.lucene.store.AlreadyClosedException: this IndexReader is closed

    Root Cause Analysis

    1. org.apache.lucene.store.AlreadyClosedException

      this IndexReader is closed

      at org.apache.lucene.index.IndexReader.ensureOpen()
    2. Lucene
      Searcher.search
      1. org.apache.lucene.index.IndexReader.ensureOpen(IndexReader.java:177)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      2. org.apache.lucene.index.IndexReader.termDocs(IndexReader.java:812)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      3. org.apache.lucene.index.SegmentReader.termDocs(SegmentReader.java:956)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      4. org.apache.lucene.search.TermQuery$TermWeight.scorer(TermQuery.java:74)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      5. org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:210)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      6. org.apache.lucene.search.IndexSearcher.search(IndexSearcher.java:170)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      7. org.apache.lucene.search.Searcher.search(Searcher.java:98)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      8. org.apache.lucene.search.Searcher.search(Searcher.java:108)[lucene-core-3.0.3.jar:3.0.3 1039909 - 2010-11-28 19:08:19]
      8 frames
    3. Maven :: Indexer Core
      DefaultNexusIndexer.addArtifactToIndex
      1. org.apache.maven.index.DefaultIndexerEngine.getOldDocument(DefaultIndexerEngine.java:158)[indexer-core-4.1.3-SONATYPE.jar:4.1.3-SONATYPE]
      2. org.apache.maven.index.DefaultIndexerEngine.update(DefaultIndexerEngine.java:77)[indexer-core-4.1.3-SONATYPE.jar:4.1.3-SONATYPE]
      3. org.apache.maven.index.DefaultNexusIndexer.addArtifactToIndex(DefaultNexusIndexer.java:371)[indexer-core-4.1.3-SONATYPE.jar:4.1.3-SONATYPE]
      3 frames
    4. Sonatype Nexus Indexer
      DefaultIndexerManager.addItemToIndex
      1. org.sonatype.nexus.index.DefaultIndexerManager.addItemToIndex(DefaultIndexerManager.java:655)[nexus-indexer-lucene-plugin-2.0.3.jar:na]
      1 frame
    5. ${project.groupId}:${project.artifactId}
      DefaultEventInspectorHost$EventInspectorHandler.run
      1. org.sonatype.nexus.events.IndexerManagerEventInspector.inspectForIndexerManager(IndexerManagerEventInspector.java:75)[nexus-indexer-lucene-plugin-2.0.3.jar:na]
      2. org.sonatype.nexus.events.IndexerManagerEventInspector.inspect(IndexerManagerEventInspector.java:60)[nexus-indexer-lucene-plugin-2.0.3.jar:na]
      3. org.sonatype.nexus.events.DefaultEventInspectorHost$EventInspectorHandler.run(DefaultEventInspectorHost.java:184)[nexus-app-2.0.3.jar:na]
      3 frames
    6. Java RT
      Thread.run
      1. java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)[na:1.6.0_27]
      2. java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)[na:1.6.0_27]
      3. java.lang.Thread.run(Thread.java:662)[na:1.6.0_27]
      3 frames