-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[for 10.4] Receive multiple users from backend for user sync #36576
Conversation
Codecov Report
@@ Coverage Diff @@
## master #36576 +/- ##
============================================
+ Coverage 64.66% 64.66% +<.01%
- Complexity 19049 19051 +2
============================================
Files 1269 1269
Lines 74498 74504 +6
Branches 1311 1311
============================================
+ Hits 48171 48177 +6
Misses 25941 25941
Partials 386 386
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## master #36576 +/- ##
============================================
+ Coverage 64.66% 64.66% +<.01%
- Complexity 19050 19052 +2
============================================
Files 1268 1268
Lines 74491 74495 +4
Branches 1311 1311
============================================
+ Hits 48171 48175 +4
Misses 25934 25934
Partials 386 386
Continue to review full report at Codecov.
|
5cb24c2
to
eb81bab
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code looks good.
I added issue #36597 to make CLI acceptance tests. |
Recieve multiple users from the backend for user sync instead of checking for single user. From the received users check if the user to be synced is available in the list. Signed-off-by: Sujith H <[email protected]>
eb81bab
to
dd84405
Compare
|
|
Looks good - I will merge. |
Receive multiple users from the backend for user sync
instead of checking for single user. From the received
users check if the user to be synced is available in
the list.
Signed-off-by: Sujith H [email protected]
Description
Problem: When admin tries to sync a user say for ldap backend, there can be cases where names like
mhof
,mhoff
,mhoffg
exist in the ldap. And when admin tries to syncmhof
, the admin gets Multiple user exists exception.What this PR proposes:
Grab all the users available from the user backend, which the admin had searched for. And then try to match the users with the user to be searched for. If there are multiple users with same user name available then throw the exception. If only one user is available then sync it, else as usual show message saying user does not exist in the backend.
Related Issue
Motivation and Context
Do not check for the count of users. Instead check if the users received from the backend contains the exact match or not.
How Has This Been Tested?
mhof
,mhoff
,mhoffg
mhof
mhoffg123
which does not exist:Screenshots (if appropriate):
Types of changes
Checklist: