# Transform exception stop and expect auto restart

**URL:** <https://discuss.elastic.co/t/transform-exception-stop-and-expect-auto-restart/309069>\
**Category:** Elasticsearch\
**Tags:** transforms\
**Created:** [July 7, 2022, 3:26am UTC](https://discuss.elastic.co/t/transform-exception-stop-and-expect-auto-restart/309069 "2022-07-07T03:26:20Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![yitiao\_feiyu](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/yitiao_feiyu/32/106414_2.png) [@yitiao\_feiyu](https://discuss.elastic.co/u/yitiao_feiyu)\
**Post date:** [July 7, 2022, 3:26am UTC](https://discuss.elastic.co/t/transform-exception-stop-and-expect-auto-restart/309069/1 "2022-07-07T03:26:20Z")

</div>

I use transform to filter and move index data. the transforom task run smoothly in nomal status. but in some case, I try to change the index setting e.g. set "number\_of\_replicas" : 0, the transtorm got exception and stop. the excption may like bellow:

> task encountered irrecoverable failure: [test\_2022-07-07/q\_ZKnVF4S0eMxvYW-RzllA] QueryShardException[failed to create query: this Analyzer is closed]; nested: AlreadyClosedException[this Analyzer is closed];; org.apache.lucene.store.AlreadyClosedException: this Analyzer is closed  
> to fix this:  
> 1.stop the transform  
> 2.start the transform again.

**expect behavior** 🙂  
transform do not stop, auto ignore the issue and retry again when catch exception. or some hook to restart task without homan handle.

---

<div class="post-metadata">

**Author:** ![sophie\_chang](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/sophie_chang/32/18008_2.png) [@sophie\_chang](https://discuss.elastic.co/u/sophie_chang)\
**Post date:** [July 7, 2022, 8:27am UTC](https://discuss.elastic.co/t/transform-exception-stop-and-expect-auto-restart/309069/2 "2022-07-07T08:27:18Z")

</div>

Yes, we are working to allow transforms to run unattended, which will be available in a future release. For example, this recent PR makes setting the number of retries to be configurable for each transform, and will allow indefinite retries. [[Transform] Implement per-transform num\_failure\_retries setting. by przemekwitek · Pull Request #87361 · elastic/elasticsearch · GitHub](https://github.com/elastic/elasticsearch/pull/87361)

---

<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:** [August 4, 2022, 8:28am UTC](https://discuss.elastic.co/t/transform-exception-stop-and-expect-auto-restart/309069/3 "2022-08-04T08:28:16Z")

</div>

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