Repository navigation
fix: add index on oc_filecache over size, parent and storage to speed… - #40633
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
cf16337 to
9306b8e
Compare
| public function changeSchema(Schema $schema, array $options): void { | ||
| $prefix = $options['tablePrefix']; | ||
| $table = $schema->getTable("{$prefix}filecache"); | ||
| $table->addIndex(['size', 'parent', 'storage']); |
There was a problem hiding this comment.
Some customers propose to change the order and put size last to optimize the index further
There was a problem hiding this comment.
Also keep in mind that the index needs to be updated if size changes.
… up Cache::calculateFolderSize
9306b8e to
701777d
Compare
|
💥 Acceptance tests pipeline apiProxySmoke-8-7-mariadb10.2-php7.4 failed. The build has been cancelled. https://drone.owncloud.com/owncloud/core/37921/173 |
|
💥 Acceptance tests pipeline webUISharingExt1-git-chrome-mariadb10.2-php7.4 failed. The build has been cancelled. https://drone.owncloud.com/owncloud/core/37920/152 |
|
💥 Acceptance tests pipeline webUISharingExt2-latest-chrome-mariadb10.2-php7.4 failed. The build has been cancelled. https://drone.owncloud.com/owncloud/core/37920/156 |
|
Kudos, SonarCloud Quality Gate passed! |








… up Cache::calculateFolderSize
Description
Folder sizes are computed quite often - especially on massive file upload.
Before
After
Related Issue
How Has This Been Tested?
Screenshots (if appropriate):
Types of changes
Checklist: