org.apache.lucene.store.AlreadyClosedException

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.

  • 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]
    via by Rich Seddon,
  • Program crashes on closing
    via docfetcher by *anonymous
    ,
  • AlreadyClosedException
    via docfetcher by *anonymous
    ,
  • Stacktrace 11_29_2016
    via docfetcher by *anonymous
    ,
  • How to safely close an IndexReader?
    via Stack Overflow by Zenofo
    ,
  • Re-opening a Lucene index
    via Stack Overflow by carlspring
    ,
    • 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]
    No Bugmate found.