Skip to content
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

Get rid of cleanFolder() in the Watcher if possible for performance #24421

Closed
PVince81 opened this issue May 3, 2016 · 4 comments
Closed

Get rid of cleanFolder() in the Watcher if possible for performance #24421

PVince81 opened this issue May 3, 2016 · 4 comments

Comments

@PVince81
Copy link
Contributor

PVince81 commented May 3, 2016

After debugging the watcher/scanner, I noticed that at the end of the scan session it will call cleanFolder($path) and will iterate over all cache entries inside that folder and call file_exists to find out whether the file still exists.

As far as I understand, diffing the children of a folder is already done in scanChildren, so not sure why it has to be done again here.

@icewind1991 can you clarify ? Can we get rid of this extra cleanup to gain some performance ?

@PVince81
Copy link
Contributor Author

PVince81 commented May 3, 2016

@PVince81
Copy link
Contributor Author

PVince81 commented May 3, 2016

Found this: https://github.com/owncloud/core/blob/v9.0.1/lib/private/files/cache/scanner.php#L397

Maybe we didn't have this piece about $removedChildren in the past which would explain the requirement for cleanFolder

@PVince81
Copy link
Contributor Author

Fixed through #25103

@PVince81
Copy link
Contributor Author

Hmm, that PR is only for fed shares.

I think we should eventually get rid of it completely.

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

No branches or pull requests

3 participants