Skip to content

Conversation

@icewind1991
Copy link
Member

@icewind1991 icewind1991 commented Jul 7, 2016

When getting share info for a folder, instead of looping over the childs and querying each one individually, use a single query to get the share status of all childs.

Gives a very significant improvement when loading large folders in the webui (not sure if the sync client is affected, depends on the properties requested)

TODO

  • also show federated shares
  • tests

cc @rullzer

@icewind1991 icewind1991 added the 2. developing Work in progress label Jul 7, 2016
@icewind1991 icewind1991 added this to the Nextcloud Next milestone Jul 7, 2016
@mention-bot
Copy link

@icewind1991, thanks for your PR! By analyzing the annotation information on this pull request, we identified @PVince81, @rullzer, @schiessle and @DeepDiver1975 to be potential reviewers

@LukasReschke
Copy link
Member

64% (2.6 seconds) faster than before? Nice! 🚀

* @param string $userId
* @param Node|null $node
* @param bool $reshares Also get the shares where $user is the owner instead of just the shares where $user is the initiator
* @return \OCP\Share\IShare[]
Copy link
Member

Choose a reason for hiding this comment

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

? This will be 9.1.0

Copy link
Member Author

Choose a reason for hiding this comment

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

fixed

@MorrisJobke
Copy link
Member

@icewind1991 What is the status of this?

@icewind1991
Copy link
Member Author

Needs more work to implement this for the various sharing backends

@icewind1991 icewind1991 force-pushed the share-types-by-folder branch 2 times, most recently from 8b8f3f8 to 19c244e Compare October 26, 2016 13:58
@rullzer rullzer self-assigned this Oct 31, 2016
icewind1991 and others added 3 commits October 31, 2016 15:55
Signed-off-by: Robin Appelman <icewind@owncloud.com>
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
@rullzer rullzer force-pushed the share-types-by-folder branch from 19c244e to ce7eb02 Compare October 31, 2016 19:30
* Merge share types correctly
* Filter share types
* Order share types

Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
@rullzer rullzer added 3. to review Waiting for reviews feature: sharing and removed 2. developing Work in progress labels Nov 1, 2016
@rullzer
Copy link
Member

rullzer commented Nov 1, 2016

Ok I think this is ready for review.

CC: @nickvergessen @MorrisJobke @schiessle @LukasReschke

@icewind1991
Copy link
Member Author

👍 for @rullzer's changes

Listing a ~1000 file folder goes from ~3000 queries to 48 😄

Tested by sharing some files and checking if they show up as shared in the file list

@LukasReschke
Copy link
Member

LGTM

@LukasReschke LukasReschke merged commit ef467c3 into master Nov 1, 2016
@LukasReschke LukasReschke deleted the share-types-by-folder branch November 1, 2016 17:44
schiessle added a commit that referenced this pull request Nov 1, 2016
Signed-off-by: Bjoern Schiessle <bjoern@schiessle.org>
R0Wi pushed a commit to R0Wi/server that referenced this pull request Nov 22, 2025
For convenience, we should have done this in UpperCase initially.

I will fix it in `nc_py_api` so that it is always converted before
comparison, but this should also be unified on the AppAPI side

Signed-off-by: Alexander Piskun <bigcat88@icloud.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants