113: snapshots r=MarinPostma a=MarinPostma
This pr adds support for snapshoting.
The snapshoting process for an index requires that no other update is processing at the same time. A mutex lock has been added to prevent a snapshot from occuring at the same time as an update, while still premitting updates to be pushed.
The list of the indexes to snapshot is first retrieved from the `UuidResolver` which also performs its snapshot.
This list is passed to the update store, which attempts to acquire a lock on the update store while it snaphots itself and it's associated index store.
This means that a snapshot can only be completed once all indexes have finished their ongoing update.
This pr also adds refactoring of the code to allow unit testing and mocking, and unit test the snapshot creation.
Co-authored-by: mpostma <postma.marin@protonmail.com>
Co-authored-by: tamo <irevoire@protonmail.ch>
Co-authored-by: marin <postma.marin@protonmail.com>
Co-authored-by: Marin Postma <postma.marin@protonmail.com>
The front must provide a BTreeSet containing the stop words
The stop_words are set at None if an empty Set is provided
add the stop-words in the http-ui interface
Use maplit in the test
and remove all the useless drop(rtxn) at the end of all tests
1315: fix armv7 r=MarinPostma a=MarinPostma
fix armv7 build
this was caused by usize being 32 bit on armv7 and 64bits on all other targeted architectures.
Co-authored-by: Marin Postma <postma.marin@protonmail.com>
1307: change ubuntu version r=MarinPostma a=MarinPostma
Change the CI ubuntu version from `latest` to `18.04` because `latest` uses a too recent version of glibc, preventing meilisearch from running on the debian version of the DO image
Co-authored-by: mpostma <postma.marin@protonmail.com>
109: Make updates atomic r=curquiza a=MarinPostma
Until now, the index_uid->uuid mapping was done before the update was written to disk in the case of automatic index creation. This was an issue when the update failed, and the index would still exists in the uuid resolver.
This is fixed by this pr, by first creating the update with an uuid if the index does not exist, and then register this uuid to the uuid resolver.
This is preliminary work to the implementation of snapshots (#19).
This pr also changes the `resolve` method on the `UuidResolver` to `get` to make it clearer.
The `create_uuid` method may be bound to disappear when the index name resolution is handled by a remote machine.
Co-authored-by: mpostma <postma.marin@protonmail.com>
115: Add the exhaustiveNbHits in search response body (returns always false) r=curquiza a=irevoire
closes#103
Co-authored-by: tamo <irevoire@protonmail.ch>
Co-authored-by: Irevoire <irevoire@protonmail.ch>