# Updating Mappings and reindexing when using MongoDB river

**URL:** https://discuss.elastic.co/t/updating-mappings-and-reindexing-when-using-mongodb-river/23598
**Category:** Elasticsearch
**Created:** [May 10, 2015, 10:59am UTC](https://discuss.elastic.co/t/updating-mappings-and-reindexing-when-using-mongodb-river/23598 "2015-05-10T10:59:46Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![Eli\_Libman](https://avatars.discourse-cdn.com/v4/letter/e/df788c/32.png) [@Eli\_Libman](https://discuss.elastic.co/u/Eli_Libman)
#### Post date: [May 10, 2015, 10:59am UTC](https://discuss.elastic.co/t/updating-mappings-and-reindexing-when-using-mongodb-river/23598/1 "2015-05-10T10:59:46Z")

</div>

Hey,  
I'm using the mongodbriver to index documents from Mongo in elastic search.  
I setup the river and the index and everything is working nicely.  
Now I would like to change an analyzer (to strip html tags) and update  
elastic search to reflect this change properly.

What would be the best way of achieving this with as little downtime and  
overhead on the mongo and ES servers?

1. create a new index with the new settings and create a new mongoriver  
(use aliasing for transitioning queries from old index to new one)

2. create new index, delete mongo river, reindex old index to new one, add  
mongo river (with initial timestamp to last doc in old index, and disable  
initial sync). (transition via aliasing ...)

3. Other/better ways?

Thanks,  
Eli

## -- Please update your bookmarks! We moved to [https://discuss.elastic.co/](https://discuss.elastic.co/)

You received this message because you are subscribed to the Google Groups "elasticsearch" group.  
To unsubscribe from this group and stop receiving emails from it, send an email to [elasticsearch+unsubscribe@googlegroups.com](mailto:elasticsearch+unsubscribe@googlegroups.com).  
To view this discussion on the web visit [https://groups.google.com/d/msgid/elasticsearch/980c95fe-4284-4cf6-9255-f8b8fa82c62e%40googlegroups.com](https://groups.google.com/d/msgid/elasticsearch/980c95fe-4284-4cf6-9255-f8b8fa82c62e%40googlegroups.com).  
For more options, visit [https://groups.google.com/d/optout](https://groups.google.com/d/optout).

---

<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, 12:14am UTC](https://discuss.elastic.co/t/updating-mappings-and-reindexing-when-using-mongodb-river/23598/2 "2017-07-06T00:14:47Z")

</div>


