zero-downtime Elasticsearch re-indexing
Allow for versioned Elasticsearch indexes:
After #328 is done, we should be able to add more than one Elasticsearch schema/search code, so we're ready to allow zero-downtime reindexing
This is when we add the table
es_indexes(name, is_active, progress)On every data updates we would update every active index. While the last index is in the process of building we could use the next-oldest active one. The idea would be for only two indexes to ever be active, the current one and the one being migrated to.
We can also consider taking advantage of index aliases to specify which index we use for searches, but we still need to send updates to all active indexes
Document how the zero-downtime indexing operation works