Elasticsearch - 批量索引错误 - 此IndexWriter已关闭

时间:2014-03-24 07:38:59

标签: lucene elasticsearch

我们正在从java应用程序将文档索引到elasticsearch中。 由于以下异常(从日志中找到),我们无法索引所有必需的文档,因为其中一些文档的索引失败

org.elasticsearch.index.engine.CreateFailedEngineException: [investigations][0] Create failed for [Event#jEbSeiQASEemf6xTHSaUZw]
        at org.elasticsearch.index.engine.internal.InternalEngine.create(InternalEngine.java:397)
        at org.elasticsearch.index.shard.service.InternalIndexShard.create(InternalIndexShard.java:382)
        at org.elasticsearch.action.bulk.TransportShardBulkAction.shardIndexOperation(TransportShardBulkAction.java:401)
        at org.elasticsearch.action.bulk.TransportShardBulkAction.shardOperationOnPrimary(TransportShardBulkAction.java:153)
        at org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction.performOnPrimary(TransportShardReplicationOperationAction.java:556)
        at org.elasticsearch.action.support.replication.TransportShardReplicationOperationAction$AsyncShardOperationAction$1.run(TransportShardReplicationOperationAction.java:426)
        at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
        at java.lang.Thread.run(Thread.java:619)
Caused by: org.apache.lucene.store.AlreadyClosedException: this IndexWriter is closed
        at org.apache.lucene.index.IndexWriter.ensureOpen(IndexWriter.java:645)
        at org.apache.lucene.index.IndexWriter.ensureOpen(IndexWriter.java:659)
        at org.apache.lucene.index.IndexWriter.updateDocument(IndexWriter.java:1525)
        at org.apache.lucene.index.IndexWriter.addDocument(IndexWriter.java:1199)
        at org.elasticsearch.index.engine.internal.InternalEngine.innerCreate(InternalEngine.java:462)
        at org.elasticsearch.index.engine.internal.InternalEngine.create(InternalEngine.java:384)

可能是什么问题?即使被索引的文档数量低至28,并且没有一个文档的大小太大,也会发生这种情况。

0 个答案:

没有答案