Create new DB index and add new condition - #39017
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. |
|
💥 Acceptance tests pipeline apiFederationToShares1-git-mariadb10.2-php7.4 failed. The build has been cancelled. |
|
💥 Acceptance tests pipeline apiFederationToShares1-10.6.0-mariadb10.2-php7.4 failed. The build has been cancelled. |
05b057b to
5b5fb46
Compare
|
LGTM code-wise. SonarCloud complains about the code coverage though because the migration file is not tested. IMO migration files should not be unit-tested, but I've seen some (core-) apps do it... |
5b5fb46 to
d52d3d4
Compare
|
💥 Acceptance tests pipeline apiFederationToShares1-latest-mariadb10.2-php7.4 failed. The build has been cancelled. |
|
💥 Acceptance tests pipeline apiFederationToShares1-git-mariadb10.2-php7.4 failed. The build has been cancelled. |
|
SonarCloud Quality Gate failed. |
|
@jvillafanez isnt there already one #37152 ? |
|
The index isn't being used properly in that particular query. You can check some research in https://github.com/owncloud/enterprise/issues/4655#issuecomment-878239622 The checked performance is described in https://github.com/owncloud/enterprise/issues/4655#issuecomment-880052549 |
|
@jvillafanez in fact I proposed the index you have in this PR long time ago (#30195 (comment)) but it was rejected at a time , with prefered one also on value. I guess then we need both.. |
|
Definitely we should have a usable index on the value, but the problems are the case insensitive search and the substring search. I don't think we can do much more without restricting the query, which would remove part of the current functionality, or adding new tables oriented to index this one. |
d52d3d4 to
0d83d28
Compare
|
Rebased and tests added. The migration has been moved to the dav app. |
|
Kudos, SonarCloud Quality Gate passed! |










Description
speed up searches in the addressbook in large setups
Related Issue
https://github.com/owncloud/enterprise/issues/4655
Motivation and Context
How Has This Been Tested?
Manually tested with 2 federated servers with around 1000 users each.
Screenshots (if appropriate):
Types of changes
Checklist: