mirror of
https://github.com/meilisearch/meilisearch.git
synced 2024-11-27 04:25:06 +08:00
change the way settings are show in updates
This commit is contained in:
parent
b33dac9faa
commit
9c0497c419
@ -102,7 +102,9 @@ impl UpdateData {
|
|||||||
UpdateData::DocumentsDeletion(deletion) => UpdateType::DocumentsDeletion {
|
UpdateData::DocumentsDeletion(deletion) => UpdateType::DocumentsDeletion {
|
||||||
number: deletion.len(),
|
number: deletion.len(),
|
||||||
},
|
},
|
||||||
UpdateData::Settings(update) => UpdateType::Settings(update.clone()),
|
UpdateData::Settings(update) => UpdateType::Settings {
|
||||||
|
settings: update.clone(),
|
||||||
|
},
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -115,7 +117,7 @@ pub enum UpdateType {
|
|||||||
DocumentsAddition { number: usize },
|
DocumentsAddition { number: usize },
|
||||||
DocumentsPartial { number: usize },
|
DocumentsPartial { number: usize },
|
||||||
DocumentsDeletion { number: usize },
|
DocumentsDeletion { number: usize },
|
||||||
Settings(SettingsUpdate),
|
Settings { settings: SettingsUpdate },
|
||||||
}
|
}
|
||||||
|
|
||||||
#[derive(Debug, Clone, Serialize, Deserialize)]
|
#[derive(Debug, Clone, Serialize, Deserialize)]
|
||||||
@ -264,7 +266,9 @@ pub fn update_task<'a, 'b>(
|
|||||||
UpdateData::Settings(settings) => {
|
UpdateData::Settings(settings) => {
|
||||||
let start = Instant::now();
|
let start = Instant::now();
|
||||||
|
|
||||||
let update_type = UpdateType::Settings(settings.clone());
|
let update_type = UpdateType::Settings {
|
||||||
|
settings: settings.clone(),
|
||||||
|
};
|
||||||
|
|
||||||
let result = apply_settings_update(
|
let result = apply_settings_update(
|
||||||
writer,
|
writer,
|
||||||
|
@ -116,7 +116,6 @@ pub fn apply_settings_update(
|
|||||||
must_reindex = true;
|
must_reindex = true;
|
||||||
},
|
},
|
||||||
_ => {
|
_ => {
|
||||||
println!("schema: {:?}", schema);
|
|
||||||
index.main.put_schema(writer, &schema)?;
|
index.main.put_schema(writer, &schema)?;
|
||||||
},
|
},
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user