I have put in place a snapshot restoration process. It's great, but I've chosen to delete the indices first (as opposed to 'closing' them). The reason I took this approach is because it is easy to know what data will exist after the process is complete: the data from the snapshot. However, the question still remains (to me) and I cannot see the answer in the docs or online.
What data will be around after a restore a snapshot, having closed the indices? Will docs written AFTER the snapshot still be present?
I'd like to know exactly what set of data will be around in this case. Please and thank you.
Assume Cluster CL-A has indices IND-1, IND-2, IND-3 and index IND-2 has documents DOC-1, DOC-2, DOC-3.
You took a snapshot SNP of index IND-2. After taking the snapshot, you add another document DOC-4 to index IND-2.
Now, if you were to try and restore the snapshot SNP in cluster CL-A then (as per my knowledge) Elasticsearch will thrown an error saying index with name IND-2 already exists and won't restore the snapshot. Alternatively, If you were to restore with a different name (IND-4) then your cluster will have indices IND-1, IND-2, IND-3, IND-4 wherein IND-4 will have documents DOC-1, DOC-2, DOC-3 and index IND-2 will have documents DOC-1, DOC-2, DOC-3, DOC-4.
In short, a restore of snapshot will not affect any existing index or documents within those indices.
Aha. Completely skipped that line. I stand corrected, thanks for pointing that out. Onto your issue, this github issue - [Restore of an existing index doesn’t restore mappings and settings](https://github.com/elastic/elasticsearch/issues/5210) might give you some idea of expected behavior.