# Getting Exception: Request cannot be executed; I/O reactor status: STOPPED

**URL:** <https://discuss.elastic.co/t/getting-exception-request-cannot-be-executed-i-o-reactor-status-stopped/236038>\
**Category:** Elasticsearch\
**Created:** [June 6, 2020, 1:11pm UTC](https://discuss.elastic.co/t/getting-exception-request-cannot-be-executed-i-o-reactor-status-stopped/236038 "2020-06-06T13:11:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Satyam\_Anand](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/satyam_anand/32/47746_2.png) [@Satyam\_Anand](https://discuss.elastic.co/u/Satyam_Anand)\
**Post date:** [June 6, 2020, 1:11pm UTC](https://discuss.elastic.co/t/getting-exception-request-cannot-be-executed-i-o-reactor-status-stopped/236038/1 "2020-06-06T13:11:27Z")

</div>

I am getting this exception.  
I am throwing an exception from my afterBulk method of listener which causes the exception to be caught in catch of `BulkRequestHandler`.

```auto
catch (Exception e) {
            logger.warn(() -> new ParameterizedMessage("Failed to execute bulk request {}.", executionId), e);
            listener.afterBulk(executionId, bulkRequest, e);
        }

```

But after that in catch block it again calls `afterBulk` and then since my afterBulk again throws the exception it is throwing the exception as well.

Questions:

1. As mentioned in the (post)[[Request cannot be executed i/o reactor status stopped](https://discuss.elastic.co/t/request-cannot-be-executed-i-o-reactor-status-stopped/195438)] we should not throw exceptions in `onFailure()`, does I need to remove the exception being thrown from my afterBulk code as it throws exception in `onFailure()`?
2. What is the reason that it causes subsequent requests to fail as well?
3. How to avoid subsequent requests failures does resetting the connection will do that?

---

<div class="post-metadata">

**Author:** ![Satyam\_Anand](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/satyam_anand/32/47746_2.png) [@Satyam\_Anand](https://discuss.elastic.co/u/Satyam_Anand)\
**Post date:** [June 12, 2020, 5:57am UTC](https://discuss.elastic.co/t/getting-exception-request-cannot-be-executed-i-o-reactor-status-stopped/236038/2 "2020-06-12T05:57:16Z")

</div>

Waiting for replies..

---

<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 10, 2020, 5:57am UTC](https://discuss.elastic.co/t/getting-exception-request-cannot-be-executed-i-o-reactor-status-stopped/236038/3 "2020-07-10T05:57:39Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
