-
-
Notifications
You must be signed in to change notification settings - Fork 4.7k
perf(files): Optimize CacheEntry creation #57514
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
Conversation
8cdfdc5 to
043708f
Compare
|
Weird that this makes such a difference... |
043708f to
dea1b7a
Compare
Not really, array in php are copy on write. So each assignment create a copy. |
dea1b7a to
b7d2a16
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.
I'm not sure if not allowing arbitrary fields doesn't break things
|
Maybe we can detect those cases and add a warning for them? |
So I checked https://github.com/search?q=org%3Anextcloud%20cacheEntryFromData&type=code and the only apps that use cacheEntryFromData are: deck, circles, talk and groupfolders. For deck, circles and talk it's about sharing and these are the same additional fields as sharing on server For groupfolders, I added the specific fields from groupfolders. It reduces a bit the optimization when listing the groupfolders but there should be significantly less groupfolders than normal files/folders, so this should be fine |
|
Thanks for checking, I think there might be some other places that set their own fields in |
a8b8719 to
35f6352
Compare
Avoid many copy on writes and create array only once. Signed-off-by: Carl Schwan <carlschwan@kde.org>
Signed-off-by: Carl Schwan <carlschwan@kde.org>
35f6352 to
0682797
Compare
Summary
TODO
Checklist
3. to review, feature component)stable32)