Skip to content

Conversation

@rullzer
Copy link
Member

@rullzer rullzer commented Apr 17, 2019

Fixes #9690

As there is no local data we have to explictly delete the data from the
objectstore.

Now this might time out if you do it via web. Maybe we should add a
warning there if you do not use local storage?

Signed-off-by: Roeland Jago Douma [email protected]

As there is no local data we have to explictly delete the data from the
objectstore.

Now this might time out if you do it via web. Maybe we should add a
warning there if you do not use local storage?

Signed-off-by: Roeland Jago Douma <[email protected]>
@rullzer rullzer added bug 3. to review Waiting for reviews labels Apr 17, 2019
@rullzer rullzer added this to the Nextcloud 17 milestone Apr 17, 2019

// Delete all files
if (!$userRoot->getStorage()->instanceOfStorage(Local::class)) {
$userRoot->delete();
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Should we just do that for all OS and then drop the lines 231 to 236?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

or should we do this in a background job?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes that was also my consideration.

So then deleting the user is:

  1. Disabling the user
  2. Setting a special flag
  3. Scheduling backgroundjob

Because we need to fetch the actual user to do the deletion. Else we can't fetch the storage etc.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense 👍

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But this is something for master. This can go in like that for the back ports and then we add the background job for master.

@MorrisJobke
Copy link
Member

I'm fine with this for back porting and doing a background job and unified handling of this across all primary storages for master.

Copy link
Member

@juliusknorr juliusknorr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Makes sense 👍

@MorrisJobke
Copy link
Member

CI fails on PHPUnit tests

@MorrisJobke MorrisJobke mentioned this pull request Jul 15, 2019
28 tasks
@MorrisJobke
Copy link
Member

CI fails on PHPUnit tests

🏓

@rullzer
Copy link
Member Author

rullzer commented Aug 15, 2019

Actually the more I think about it the more it will most likely timeout. If you try to do this from the user management. Let me move this to 18 and see if we can soon come up with a proper backportable way that won't time out and do 💥

@rullzer rullzer modified the milestones: Nextcloud 17, Nextcloud 18 Aug 15, 2019
@rullzer rullzer closed this Nov 6, 2019
@rullzer rullzer deleted the fix/9690/delete_objectstore_data_on_user_deletion branch November 6, 2019 09:20
@JUVOJustin
Copy link

Is this already implemented in nc 17 and 18? As far as i can see, this bug still exists. Take a look at #9690

@IIPoliII
Copy link

IIPoliII commented Nov 2, 2020

For me on NC 20 the issue is still present...

Copy link

@IIPoliII IIPoliII left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This fix works for me ....

Copy link

@IIPoliII IIPoliII left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Works great but only using php-cli without timeout

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

3. to review Waiting for reviews bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

occ user:delete does not remove storage and files where using Swift as primary store

7 participants