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
fix: delete all files from object store when user is deleted #40959
Conversation
Thanks for opening this pull request! The maintainers of this repository would appreciate it if you would create a changelog item based on your changes. |
5beff20
to
e28588c
Compare
@phil-davis because the full user deletion is moved to cron/command bus acceptance tests are having issues. https://drone.owncloud.com/owncloud/core/39034/37/14 I suggest to run cron after deleting a user via API or use the occ command user:delete because this will not delete via cron. THX |
For end-of-scenario cleanup, I can sort out the code so that it does a proper real delete of the user. For example, change the test code so that it does But there are also scenarios that test the provisioning API DELETE behavior. That Provisioning API endpoint now has different behavior - do I understand correctly? |
That is a good point. Depending on the cron setup it can take minutes until a user is deleted. |
After the Provisioning API DELETE request is processed, what is the external status of the user:
There will be situations when an admin is deleting a user for "immediate" security reasons. I suppose for that case, the admin can first disable the user, preventing access. Then the user delete can be more async. Maybe a delete can be done by doing a disable synchronously, and leaving the actual user deletion/file-deletion to later. That should preserve security, and still allow the "bigger" file deletion to be done later in the background. |
e28588c
to
b074a88
Compare
I decided to skip the command bus. All user delete operations are now done synchronous. |
Small remark about a variable's name. Apart from this, code looks ok and manual testing confirms the correct behaviour: files are removed from the object store as soon as the user gets deleted. |
CI fail is not related. |
b074a88
to
20e30cc
Compare
CI can now access the WND server again! |
Kudos, SonarCloud Quality Gate passed! |
@DeepDiver1975 merge this or additional review needed? |
Description
As soon as a user is deleted files will also be removed from object storage (s3).
Motivation and Context
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist: