mirror of
https://github.com/meilisearch/meilisearch.git
synced 2025-10-29 06:56:45 +00:00
Separate the update and main databases
We used the heed typed transaction to make it safe (https://github.com/Kerollmops/heed/pull/27).
This commit is contained in:
@@ -1,9 +1,11 @@
|
||||
use crate::store;
|
||||
use crate::update::{next_update_id, Update};
|
||||
use heed::Result as ZResult;
|
||||
|
||||
use crate::database::{MainT, UpdateT};
|
||||
use crate::store;
|
||||
use crate::update::{next_update_id, Update};
|
||||
|
||||
pub fn apply_customs_update(
|
||||
writer: &mut heed::RwTxn,
|
||||
writer: &mut heed::RwTxn<MainT>,
|
||||
main_store: store::Main,
|
||||
customs: &[u8],
|
||||
) -> ZResult<()> {
|
||||
@@ -11,7 +13,7 @@ pub fn apply_customs_update(
|
||||
}
|
||||
|
||||
pub fn push_customs_update(
|
||||
writer: &mut heed::RwTxn,
|
||||
writer: &mut heed::RwTxn<UpdateT>,
|
||||
updates_store: store::Updates,
|
||||
updates_results_store: store::UpdatesResults,
|
||||
customs: Vec<u8>,
|
||||
|
||||
Reference in New Issue
Block a user