Commit Graph

95 Commits (master)

Author SHA1 Message Date
Varun Patil 5bb0a29339 perf(core): add index on name
Signed-off-by: Varun Patil <varunpatil@ucla.edu>
2 months ago
Daniel Kesselberg bddd45fdf3
fix(db): remove redundant index in cards
Follow up for https://github.com/nextcloud/server/pull/43340

Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2 months ago
Josh bd6fecff4e
fix(db): Remove duplicate missing index check for `cards`
Signed-off-by: Josh <josh.t.richards@gmail.com>
3 months ago
Joas Schilling 226134a195
fix(comments): Reference ID column is now added on upgrade and therefore can be removed
Signed-off-by: Joas Schilling <coding@schilljs.com>
5 months ago
Julius Härtl 1cfc8a2e03
Revert "perf: Add partial index on configvalue of preferences table"
This reverts commit 0ccf84bb31.

Signed-off-by: Julius Härtl <jus@bitgrid.net>
5 months ago
Julius Härtl 0ccf84bb31
perf: Add partial index on configvalue of preferences table
Signed-off-by: Julius Härtl <jus@bitgrid.net>
6 months ago
Louis Chemineau d3a313f192
Support getting and setting metadata in DAV requests
Signed-off-by: Louis Chemineau <louis@chmn.me>
6 months ago
Robin Appelman ccf57e0715 add separate event for rendering login page template
Signed-off-by: Robin Appelman <robin@icewind.nl>
9 months ago
Joas Schilling 86310a35b2
fix(db): Move missing core indices to typed event
Signed-off-by: Joas Schilling <coding@schilljs.com>
10 months ago
Joas Schilling f73f14207c
fix(db): Move missing core columns to typed event
Signed-off-by: Joas Schilling <coding@schilljs.com>
10 months ago
Joas Schilling 77c2b169a5
fix(db): Move missing core primary keys to typed event
Signed-off-by: Joas Schilling <coding@schilljs.com>
10 months ago
Marcel Klehr fcf1c3033b fix(systemtags): Add missing systemtags index
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
11 months ago
Robin Appelman db43d90387
add new index in repair step instead of on-migrate
Signed-off-by: Robin Appelman <robin@icewind.nl>
1 year ago
Louis Chemineau bda66f9fb6 Add parent index on filecache
Signed-off-by: Louis Chemineau <louis@chmn.me>
1 year ago
John Molakvoæ a8e8a89ade
Only check unsupported browsers on user rendering
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2 years ago
Carl Schwan 92a5a8f075 Cleanup tags and Share component
- Port to LoggerInterface
- Use IDBConnection and IQueryBuilder instead of raw SQL and OC_DB
- Use IEventListener instead of hooks
- Remove the now unused OC_DB and OC_DB_StatementWrapper legacy utils

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 years ago
Marcel Klehr 047cc708d4 DB mounts table: Add index for mount_provider_class
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2 years ago
Julius Härtl f4135c72f5
Merge pull request #31047 from nextcloud/enh/preferences-index
Additional index on oc_preferences to make queries without a user filter faster
2 years ago
Julius Härtl 7fbd93b2ad
Additional index on oc_preferences to make sure that gettingh values without a user filter is fast
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2 years ago
Carl Schwan 7817845538 Add a metadata service to store file metadata
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2 years ago
Julius Härtl 415294e345
Add index for direct editing cleanup job
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2 years ago
Christoph Wurst ed84f07784
Add missing index for propertypath only queries against properties
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2 years ago
Joas Schilling 536a812de4
Add an index for selecting the next job
Signed-off-by: Joas Schilling <coding@schilljs.com>
2 years ago
Robin Appelman 695326534c
disable path prefix index on postgresql for now
having the index work properly for the queries we need it for requires some additional options which dbal does not support at the momement.
to prevent making it harder to add the correct index later on we don't create the index for now on postgresql

Signed-off-by: Robin Appelman <robin@icewind.nl>
3 years ago
Robin Appelman abd6b354ac
add a prefix index to filecache.path
The reason that `filecache.path` hasn't had an index added is the mysql limitation of ~1kb for indexeded fields,
which is to small for the `path`, however mysql supports indexing only the first N bytes of a column instead of the entire column,
allowing us to add an index even if the column is to long.

Because the index doesn't cover the entire column it can't be used in all situations where a normal index would be used, but it does cover the `path like 'folder/path/%'` queries that are used in various places.

Sqlite and Postgresql don't support prefix indexes, but they also don't have the 1kb limit and DBAL handles the differences in index creation.

Signed-off-by: Robin Appelman <robin@icewind.nl>
3 years ago
Robin Appelman 6502dfae34
add better index for finding unindexed paths
for the following query 'SELECT "path" FROM "oc_filecache" WHERE ("storage" = $storage) AND ("size" < 0) ORDER BY "fileid" DESC LIMIT 1;'

currently the database will in some cases decide to priorize the sort by fileid over the filter when picking what index to use, resulting in a much slower query.

by creating an index that allows first sorting by fileid and also filter by storage and size this case will be greatly sped up

Signed-off-by: Robin Appelman <robin@icewind.nl>
3 years ago
Morris Jobke dbed0ce680
Properly cleanup entries of WebAuthn on user deletion
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
3 years ago
John Molakvoæ (skjnldsv) 215aef3cbd
Update php licenses
Signed-off-by: John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com>
3 years ago
Robin Appelman ed2d02d5f1
better cleanup of user files on user deletion
Signed-off-by: Robin Appelman <robin@icewind.nl>
3 years ago
Roeland Jago Douma 14ee17e5c5
Revert "add a prefix index to filecache.path" 3 years ago
Robin Appelman b28f0a0e94
add a prefix index to filecache.path
The reason that `filecache.path` hasn't had an index added is the mysql limitation of ~1kb for indexeded fields,
which is to small for the `path`, however mysql supports indexing only the first N bytes of a column instead of the entire column,
allowing us to add an index even if the column is to long.

Because the index doesn't cover the entire column it can't be used in all situations where a normal index would be used, but it does cover the `path like 'folder/path/%'` queries that are used in various places.

Sqlite and Postgresql don't support prefix indexes, but they also don't have the 1kb limit and DBAL handles the differences in index creation.

Signed-off-by: Robin Appelman <robin@icewind.nl>
3 years ago
Christoph Wurst 8b64e92b92
Bump doctrine/dbal from 2.12.0 to 3.0.0
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 years ago
Christoph Wurst d89a75be0b
Update all license headers for Nextcloud 21
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
3 years ago
Julius Härtl c77e259cfe
Add missing index on oc_cards and rename if it previously existed
Signed-off-by: Julius Härtl <jus@bitgrid.net>
3 years ago
Morris Jobke c0a05c0412
Add notification for user limit
Signed-off-by: Morris Jobke <hey@morrisjobke.de>
4 years ago
Joas Schilling d5df033ede
Create primary keys on all tables and add a command to create the afterwards
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Roeland Jago Douma 22f04a7cc3
Fix invalid usages of the new dispatcher
Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
4 years ago
Robin Appelman 634c051be6
add size index for filecache
improves performance of #23004

Signed-off-by: Robin Appelman <robin@icewind.nl>
4 years ago
Christoph Wurst 2a054e6c04
Update the license headers for Nextcloud 20
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst 3474afa938
Clean up auth tokens when user is deleted
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Mario Danic 6e28c2807b
Add index to properties table
Signed-off-by: Mario Danic <mario@lovelyhq.com>
4 years ago
Christoph Wurst cb057829f7
Update license headers for 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst caff1023ea
Format control structures, classes, methods and function
To continue this formatting madness, here's a tiny patch that adds
unified formatting for control structures like if and loops as well as
classes, their methods and anonymous functions. This basically forces
the constructs to start on the same line. This is not exactly what PSR2
wants, but I think we can have a few exceptions with "our" style. The
starting of braces on the same line is pracrically standard for our
code.

This also removes and empty lines from method/function bodies at the
beginning and end.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Joas Schilling bc6a5ef5c4
Merge pull request #19890 from nextcloud/enh/comments-reference-id
Add optional comments reference_id
4 years ago
Christoph Wurst 1a9330cd69
Update the license headers for Nextcloud 19
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Joas Schilling 720dc4e93d
Add optional column oc_comments.reference_id
Signed-off-by: Joas Schilling <coding@schilljs.com>
4 years ago
Christoph Wurst 74936c49ea
Remove unused imports
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst 60d4b45e89
Clean up 2FA provider registry when a user is deleted
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
4 years ago
Christoph Wurst 5bf3d1bb38
Update license headers
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
5 years ago
Thomas Citharel 68cf47e947
Check and add index on principaluri for schedulingobjects table
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
5 years ago