-
-
Notifications
You must be signed in to change notification settings - Fork 4.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
[stable26] invalidate existing tokens when deleting an oauth client #37230
Conversation
@@ -92,6 +104,11 @@ public function addClient(string $name, | |||
|
|||
public function deleteClient(int $id): JSONResponse { | |||
$client = $this->clientMapper->getByUid($id); | |||
|
|||
$this->userManager->callForAllUsers(function (IUser $user) use ($client) { |
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.
should be run for known users, not all users, and not in user facing requests as it may take ages
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.
The same thing was merged in master and stable24 already :-/
Why would it take ages?
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.
because it will ask all connected backends to all users. not an issue on small local instance, but a factor on big setups.
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.
@blizzz do you mean using callForSeenUsers()
instead of callForAllUsers()
?
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.
@blizzz do you mean using
callForSeenUsers()
instead ofcallForAllUsers()
?
yes, and ideally it runs through background jobs only
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.
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.
Depending on the instance size it may cycle over x thousands of users.
moving to 26.0.1 (as final RC3 is due) |
55e0975
to
e25b640
Compare
This will need to be backported to stable25, and the callForSeenUser change needs to be ported to master as well in a smaller PR |
CI is failing, at least PHPUnit / phpunit-oci (8.2) might be related |
→ 26.0.3 |
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
Signed-off-by: Artur Neumann <[email protected]>
e25b640
to
cb005f6
Compare
Signed-off-by: Artur Neumann <[email protected]>
@blizzz unit tests fixed, also for the other repos |
Signed-off-by: Arthur Schiwon <[email protected]>
backport of #36033