mirror of
https://github.com/meilisearch/MeiliSearch
synced 2025-07-04 20:37:15 +02:00
test the details of all tasks type
This commit is contained in:
parent
6167baa9eb
commit
1cf081f9a3
4 changed files with 642 additions and 3 deletions
|
@ -439,6 +439,7 @@ pub async fn update_all(
|
|||
Some(&req),
|
||||
);
|
||||
|
||||
println!("Registering a setting update");
|
||||
let allow_index_creation = index_scheduler.filters().allow_index_creation;
|
||||
let index_uid = IndexUid::try_from(index_uid.into_inner())?.into_inner();
|
||||
let task = KindWithContent::SettingsUpdate {
|
||||
|
|
|
@ -20,7 +20,7 @@ pub fn configure(cfg: &mut web::ServiceConfig) {
|
|||
#[derive(Deserialize, Debug, Clone, PartialEq, Eq)]
|
||||
#[serde(rename_all = "camelCase", deny_unknown_fields)]
|
||||
pub struct SwapIndexesPayload {
|
||||
swap: (String, String),
|
||||
indexes: (String, String),
|
||||
}
|
||||
|
||||
pub async fn swap_indexes(
|
||||
|
@ -33,7 +33,7 @@ pub async fn swap_indexes(
|
|||
let mut indexes_set = HashSet::<String>::default();
|
||||
let mut unknown_indexes = HashSet::new();
|
||||
let mut duplicate_indexes = HashSet::new();
|
||||
for SwapIndexesPayload { swap: (lhs, rhs) } in params.into_inner().into_iter() {
|
||||
for SwapIndexesPayload { indexes: (lhs, rhs) } in params.into_inner().into_iter() {
|
||||
if !search_rules.is_index_authorized(&lhs) {
|
||||
unknown_indexes.insert(lhs.clone());
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue