Allow Atlas Search indexes to be restored across clusters
Currently, when an Atlas backup snapshot from one environment is restored to another environment, it does not transfer or replicate the Atlas Search indexes from the source cluster to the destination cluster. As a result, after the snapshot is restored, the Atlas Search indexes have to be manually created on the collections in the destination cluster.
This is a request for a functionality that will allow a snapshot-restore from one cluster to another to also replicate the Atlas Search indexes from the source cluster to the destination cluster.
Atlas Search index definitions are now included in Cloud Backup snapshots of M10 or higher clusters. See Atlas Search Changelog.
-
Marces Engel commented
What about mongorestore, would that also be possible? We need to redact our snapshots before applying them to a different cluster, which'd be problematic with the discussed approach (unless we create an intermediate cluster for the redaction process, which we'd like to prevent).
-
Eric commented
I'm assuming that mongorestore doesn't actually rebuild the indexes on the target cluster. If it does then, a mongodump of the Atlas Search Index collection, a mongorestore to another cluster and finally kick off Atlas Search indexing via command line call is the approach I will take. This is for me to copy my autocomplete index from production to dev and staging. At the moment, I have a small amount of records, ~1500 to run autocomplete indexing on. But as that collection grows, I'm assuming it may end up taking non-trivial amount of time to build the index on my dev and staging nodes.