# Can restore process go through preprocessors?

**URL:** <https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605>\
**Category:** Elasticsearch\
**Created:** [October 27, 2017, 7:23pm UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605 "2017-10-27T19:23:55Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![webattitude](https://avatars.discourse-cdn.com/v4/letter/w/258eb7/32.png) [@webattitude](https://discuss.elastic.co/u/webattitude)\
**Post date:** [October 27, 2017, 7:23pm UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605/1 "2017-10-27T19:23:55Z")

</div>

Hi, here is my use case :  
I'd like to let a date preprocessor rename indices while they are restored, based on a timestamp field in documents.

---

<div class="post-metadata">

**Author:** ![Igor\_Motov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igor_motov/32/45193_2.png) [@Igor\_Motov](https://discuss.elastic.co/u/Igor_Motov)\
**Post date:** [October 27, 2017, 11:01pm UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605/2 "2017-10-27T23:01:07Z")

</div>

You can change the index name using [script processor](https://www.elastic.co/guide/en/elasticsearch/reference/master/script-processor.html#script-processor), but I am not quite sure what you mean by "date preprocessor" and what phrase "while they are restored" means in this context, so this might be not what you are actually looking for. If this is the case, could you clarify your question?

---

<div class="post-metadata">

**Author:** ![webattitude](https://avatars.discourse-cdn.com/v4/letter/w/258eb7/32.png) [@webattitude](https://discuss.elastic.co/u/webattitude)\
**Post date:** [October 28, 2017, 12:11am UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605/3 "2017-10-28T00:11:46Z")

</div>

I'd like to use this processor [https://www.elastic.co/guide/en/elasticsearch/reference/master/date-index-name-processor.html](https://www.elastic.co/guide/en/elasticsearch/reference/master/date-index-name-processor.html) during restore process, I mean during snapshot backup and restore process ([https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-snapshots.html](https://www.elastic.co/guide/en/elasticsearch/reference/current/modules-snapshots.html)).

---

<div class="post-metadata">

**Author:** ![Igor\_Motov](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/igor_motov/32/45193_2.png) [@Igor\_Motov](https://discuss.elastic.co/u/Igor_Motov)\
**Post date:** [October 28, 2017, 12:45am UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605/4 "2017-10-28T00:45:43Z")

</div>

You cannot use any processors during restore process, because restore process doesn't reindex your data. It just copies files from repository to the data directory on the nodes. During the restore (until the index is open) we are not even trying to look at the content of these files (except calculating checksums), so there is no way to lookup timestamps from these document or do any operations based on the content of the documents, or split documents from one index into multiple indices.

---

<div class="post-metadata">

**Author:** ![webattitude](https://avatars.discourse-cdn.com/v4/letter/w/258eb7/32.png) [@webattitude](https://discuss.elastic.co/u/webattitude)\
**Post date:** [October 28, 2017, 12:50am UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605/5 "2017-10-28T00:50:40Z")

</div>

Ok thanks for your answer

---

<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:** [November 25, 2017, 12:51am UTC](https://discuss.elastic.co/t/can-restore-process-go-through-preprocessors/105605/6 "2017-11-25T00:51:21Z")

</div>

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