Skip to content

Commit

Permalink
fix: ldap sync possible distributed deadlock (#762)
Browse files Browse the repository at this point in the history
  • Loading branch information
RWDai authored Jun 4, 2024
1 parent 6f453dd commit addc991
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions backend/supports/iam/src/basic/serv/iam_cert_serv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -1429,15 +1429,17 @@ impl IamCertServ {
return Err(funs.err().conflict("ldap_account", "sync", "should have sync config!", "iam-not-found-sync-config"));
};

let result = match sync_config.account_sync_from {
match sync_config.account_sync_from {
IamCertExtKind::Ldap => {
IamCertLdapServ::iam_sync_ldap_user_to_iam(sync_config, &funs, &task_ctx).await?;
Ok(())
}
_ => Err(funs.err().not_implemented("third_integration", "sync", "501-sync-from-is-not-implemented", "501-sync-from-is-not-implemented")),
_ => {
funs.err().not_implemented("third_integration", "sync", "501-sync-from-is-not-implemented", "501-sync-from-is-not-implemented");
}
};
drop(sync);
result
Ok(())
},
&funs.cache(),
ws_iam_send_client().await.clone(),
Expand Down

0 comments on commit addc991

Please sign in to comment.