# Custom document processing during indexing

**URL:** <https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620>\
**Category:** Elasticsearch\
**Created:** [November 15, 2015, 4:54pm UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620 "2015-11-15T16:54:55Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![ashoka\_klt](https://avatars.discourse-cdn.com/v4/letter/a/ac91a4/32.png) [@ashoka\_klt](https://discuss.elastic.co/u/ashoka_klt)\
**Post date:** [November 15, 2015, 4:54pm UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620/1 "2015-11-15T16:54:55Z")

</div>

I am new to elasticsearch. I want to do some custom processing while indexing a document and store the processed output to different set of fields. Is there any option available in elasticsearch to do custom document processing during indexing?

---

<div class="post-metadata">

**Author:** ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)\
**Post date:** [November 15, 2015, 5:15pm UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620/2 "2015-11-15T17:15:55Z")

</div>

At this point there isn't a good option. There is a node ingest feature  
under development that will help. For now I suggest doing it in your  
application.

---

<div class="post-metadata">

**Author:** ![GlenRSmith](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/glenrsmith/32/44925_2.png) [@GlenRSmith](https://discuss.elastic.co/u/GlenRSmith)\
**Post date:** [November 15, 2015, 7:30pm UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620/3 "2015-11-15T19:30:12Z")

</div>

You might wish to investigate [Transform](https://www.elastic.co/guide/en/elasticsearch/reference/1.7/mapping-transform.html) to see if you can accomplish what you want that way.

---

<div class="post-metadata">

**Author:** ![nik9000](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/nik9000/32/44947_2.png) [@nik9000](https://discuss.elastic.co/u/nik9000)\
**Post date:** [November 15, 2015, 7:50pm UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620/4 "2015-11-15T19:50:32Z")

</div>

Stay away from transform. It makes debugging hard and its deprecated in 2.0  
and has been removed entirely in 3.0. It was written for the rare cases  
when you want the source to differ from what is indexed in non-obvious  
ways. It's not a document processing thing. It just kind of looks like one.

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [November 16, 2015, 3:12am UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620/5 "2015-11-16T03:12:08Z")

</div>

Depends what you want to do, but maybe Logstash can help?

---

<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 5, 2017, 11:38pm UTC](https://discuss.elastic.co/t/custom-document-processing-during-indexing/34620/6 "2017-07-05T23:38:21Z")

</div>


