# Getting org.elasticsearch.index.engine.EngineClosedException while indexing documets

**URL:** <https://discuss.elastic.co/t/getting-org-elasticsearch-index-engine-engineclosedexception-while-indexing-documets/7415>\
**Category:** Elasticsearch\
**Created:** [April 20, 2012, 8:17am UTC](https://discuss.elastic.co/t/getting-org-elasticsearch-index-engine-engineclosedexception-while-indexing-documets/7415 "2012-04-20T08:17:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![AshutoshB](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/ashutoshb/32/28577_2.png) [@AshutoshB](https://discuss.elastic.co/u/AshutoshB)\
**Post date:** [April 20, 2012, 8:17am UTC](https://discuss.elastic.co/t/getting-org-elasticsearch-index-engine-engineclosedexception-while-indexing-documets/7415/1 "2012-04-20T08:17:43Z")

</div>

Hi All,

I am using Elastic Search 0.19.1 for our application. I am running 3 nodes  
with default settings except cluster.name. While indexing some documents I  
am getting following exception :

[2012-04-19 19:33:06,671][WARN][index.engine.robin] [Beckley,  
Benny] [nextlevel-bdm1][4] failed to flush after setting shard to inactive  
org.elasticsearch.index.engine.EngineClosedException: [nextlevel-bdm1][4]  
CurrentState[CLOSED]  
at  
org.elasticsearch.index.engine.robin.RobinEngine.flush(RobinEngine.java:779)

```
    at 

```

org.elasticsearch.index.engine.robin.RobinEngine.updateIndexingBufferSize(RobinEngine.java:218)

```
    at 

```

org.elasticsearch.indices.memory.IndexingMemoryController$ShardsIndicesStatusChecker.run(IndexingMemoryController.java:178)

```
    at 

```

org.elasticsearch.threadpool.ThreadPool$LoggingRunnable.run(ThreadPool.java:279)

```
    at 

```

java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)  
at  
java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)  
at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)  
at  
java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)

```
    at 

```

java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:180)

```
    at 

```

java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:204)

```
    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:662) 

```

Can anyone suggest me what could be the probable reason for the exception  
and what are the steps should follow to remove the exception?

Best,  
Ashutosh

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [April 21, 2012, 2:49pm UTC](https://discuss.elastic.co/t/getting-org-elasticsearch-index-engine-engineclosedexception-while-indexing-documets/7415/2 "2012-04-21T14:49:33Z")

</div>

You can ignore this failure, I will push a fix to not print this log  
message (its perfectly fine).

On Fri, Apr 20, 2012 at 11:17 AM, Ashutosh Bhattacharya \<  
[ashutosh.bhattacharya.in@gmail.com](mailto:ashutosh.bhattacharya.in@gmail.com)\> wrote:

> Hi All,
> 
> I am using Elastic Search 0.19.1 for our application. I am running 3 nodes  
> with default settings except cluster.name. While indexing some documents  
> I am getting following exception :
> 
> [2012-04-19 19:33:06,671][WARN][index.engine.robin] [Beckley,  
> Benny] [nextlevel-bdm1][4] failed to flush after setting shard to inactive  
> org.elasticsearch.index.engine.EngineClosedException: [nextlevel-bdm1][4]  
> CurrentState[CLOSED]  
> at  
> org.elasticsearch.index.engine.robin.RobinEngine.flush(RobinEngine.java:779)
> 
> ```
> at
> 
> ```
> 
> org.elasticsearch.index.engine.robin.RobinEngine.updateIndexingBufferSize(RobinEngine.java:218)
> 
> ```
> at
> 
> ```
> 
> org.elasticsearch.indices.memory.IndexingMemoryController$ShardsIndicesStatusChecker.run(IndexingMemoryController.java:178)
> 
> ```
> at
> 
> ```
> 
> org.elasticsearch.threadpool.ThreadPool$LoggingRunnable.run(ThreadPool.java:279)
> 
> ```
> at
> 
> ```
> 
> java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)  
> at  
> java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)  
> at  
> java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)  
> at  
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
> 
> ```
> at
> 
> ```
> 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:180)
> 
> ```
> at
> 
> ```
> 
> java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:204)
> 
> ```
> 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:662)
> 
> ```
> 
> Can anyone suggest me what could be the probable reason for the exception  
> and what are the steps should follow to remove the exception?
> 
> Best,  
> Ashutosh

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 6, 2017, 3:31am UTC](https://discuss.elastic.co/t/getting-org-elasticsearch-index-engine-engineclosedexception-while-indexing-documets/7415/3 "2017-07-06T03:31:30Z")

</div>


