-
Notifications
You must be signed in to change notification settings - Fork 156
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
[full-ci] Improve performance when loading folders and share indicators #8349
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. |
Results for e2e-tests oCIS https://drone.owncloud.com/owncloud/web/32517/12/1 💥 To see the trace, please open the link in the console ...
npx playwright show-trace https://cache.owncloud.com/public/owncloud/web/32517/tracing/participant-management-alice-2023-2-7-12-02-29.zipnpx playwright show-trace https://cache.owncloud.com/public/owncloud/web/32517/tracing/participant-management-anonymous-2023-2-7-12-03-02.zipnpx playwright show-trace https://cache.owncloud.com/public/owncloud/web/32517/tracing/participant-management-brian-2023-2-7-12-02-38.zipnpx playwright show-trace https://cache.owncloud.com/public/owncloud/web/32517/tracing/participant-management-carol-2023-2-7-12-02-51.zipnpx playwright show-trace https://cache.owncloud.com/public/owncloud/web/32517/tracing/participant-management-marie-2023-2-7-12-02-42.zipnpx playwright show-trace https://cache.owncloud.com/public/owncloud/web/32517/tracing/participant-management-richard-2023-2-7-12-02-46.zip |
Results for acceptance oC10 https://drone.owncloud.com/owncloud/web/32508/31/1 💥 The acceptance tests failed on retry. Please find the screenshots inside ...
webUISharingInternalGroupsSharingIndicator-shareWithGroups_feature-L65.pngwebUISharingInternalGroupsSharingIndicator-shareWithGroups_feature-L86.pngwebUISharingInternalGroupsToRootSharingIndicator-shareWithGroups_feature-L58.pngwebUISharingInternalGroupsToRootSharingIndicator-shareWithGroups_feature-L74.pngwebUISharingInternalUsersSharingIndicator-shareWithUsers_feature-L104.pngwebUISharingInternalUsersSharingIndicator-shareWithUsers_feature-L127.pngwebUISharingInternalUsersToRootSharingIndicator-shareWithUsers_feature-L52.pngwebUISharingInternalUsersToRootSharingIndicator-shareWithUsers_feature-L69.png |
32b7583
to
e4f428f
Compare
e4f428f
to
45a1b29
Compare
Status: The indicator loading when adding or removing shares still has some fllaws. We also need the parent folders here, so that needs to be implemented properly first. Where do we want to load the parent folders? How do we persist them? Edit: See #8383 |
45a1b29
to
882fb2c
Compare
882fb2c
to
6954df2
Compare
changelog/unreleased/bugfix-loading-shares-in-deep-nested-folders
Outdated
Show resolved
Hide resolved
@@ -0,0 +1,6 @@ | |||
Enhancement: Improve performance when loading folders and share indicators |
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.
❤️
packages/web-app-files/src/components/AppBar/CreateAndUpload.vue
Outdated
Show resolved
Hide resolved
packages/web-app-files/src/components/SideBar/Details/FileDetails.vue
Outdated
Show resolved
Hide resolved
@@ -254,8 +255,11 @@ export default defineComponent({ | |||
} | |||
|
|||
watch( | |||
selectedFiles, | |||
() => [...unref(selectedFiles), props.open], | |||
(newResource, oldResource) => { |
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 callback args newResource
and oldResource
are not a list of resources anymore, because you added an additional attribute in the watcher. They are now arrays of resources and an additional boolean. That breaks the check in line 275 on !!oldResource
.
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.
Good catch, thx! I removed it completely, as we don't need it anymore. There is still room for some improvements when navigating with an opened sidebar, but it's already 100 times better than before.
cc @pascalwengerter @diocas @elizavetaRa this PR removes the ugly loading of shares via ocs in the file list (for the share indicators) and switches to super slim propfinds on parent folders. I think this should be pretty noticeable in cernbox. @JammingBen also tried to make the |
Kudos, SonarCloud Quality Gate passed! |
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.
❤️
Description
sharesTree
manually instead of re-loading it completelyshareType
property on the resource (for direct shares) and on the parent folders (for indirect shares).sharesTree
is now only loaded when accessing the sidebar (before, it was loaded as soon as you navigated into a folder, as well as on resource creation).Related Issue
Types of changes
To-Dos
depth: 0
getParentFolders()
usage inFileDetails
!!this.currentFolder?.shareTypes?.length
check inCreateAndUpload.vue
shareType
andpath
when listing all parent folders