Commit graph

408 commits

Author SHA1 Message Date
Louis Chemineau
45e4d590e0 Add parent index on filecache
Signed-off-by: Louis Chemineau <louis@chmn.me>
2023-04-06 11:25:20 +00:00
Joas Schilling
51c2a51fed
Fail the repair command when an error happened
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-02-28 09:15:31 +01:00
Robin Appelman
5f6c17610f fix repairing non user shares when repairing all shares
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-08 22:38:39 +00:00
Robin Appelman
22e053771a split repairing into two stages to prevent long open transaction
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-08 22:38:34 +00:00
Robin Appelman
54177019f2 update shares directly in db
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-08 22:38:33 +00:00
Vincent Petry
52f10b18ee More verbose output for repair share ownership cmd
Signed-off-by: Vincent Petry <vincent@nextcloud.com>
2022-11-08 22:38:33 +00:00
Robin Appelman
a4edde3f70 move share owner repair to occ command
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-08 22:38:32 +00:00
Marcel Klehr
7710ea24bf
Merge pull request #34798 from nextcloud/backport/33405/stable24 2022-10-27 13:58:58 +02:00
Marcel Klehr
67af99e14e DB mounts table: Add index for mount_provider_class
Signed-off-by: Marcel Klehr <mklehr@gmx.net>
2022-10-27 11:56:37 +02:00
Daniel Kesselberg
a7bf60772a Fix Uninitialized string offset 0 at GenerateMimetypeFileBuilder.php#39
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2022-10-25 08:31:59 +00:00
timm2k
9f32f34b07 Update ConvertFilecacheBigInt.php
Signed-off-by: timm2k <timm2k@gmx.de>
2022-09-15 12:08:54 +00:00
Daniel Kesselberg
7abb4c3044 Fix undefined when no tags
Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
2022-06-29 13:15:59 +00:00
Joas Schilling
cfd2e8cc20
Allow to autocomplete user and group ids in commands
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-04-08 11:54:44 +02:00
blizzz
835e28d0b2
Merge pull request #31661 from nextcloud/enh/user_ldap-add-command-to-unmap-groups
Add ldap:reset-group command to unmap groups from LDAP
2022-04-05 10:57:33 +02:00
Christoph Wurst
498d3aea06
Merge pull request #31687 from nextcloud/enhancement/passwordless-app-passwords
Allow app passwords without login password for occ user:add-app-password
2022-04-04 11:46:17 +02:00
Côme Chilliet
77bdad84c2 Add ldap:reset-group command to unmap groups from LDAP
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-04-01 12:18:02 +00:00
Côme Chilliet
9191ca43ce
Merge pull request #31735 from nextcloud/fix/noid/mig-generator-copyright
migration generator also includes copyright section
2022-03-29 16:49:43 +02:00
Côme Chilliet
765999f454
Merge pull request #31609 from nextcloud/fix/migrate-away-from-ilogger
Migrate from ILogger to LoggerInterface in lib/private
2022-03-29 09:39:38 +02:00
Arthur Schiwon
ee006563ae
migration generator also includes copyright section
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2022-03-28 15:35:17 +02:00
Côme Chilliet
ea23523c70
Adapt more code to migration to LoggerInterface
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-03-24 16:21:25 +01:00
Louis Chemineau
970fb7ce65 Don't create cards_abiduri it if already exists
Signed-off-by: Louis Chemineau <louis@chmn.me>
2022-03-24 10:42:22 +00:00
Christoph Wurst
515235163c
Allow app passwords without login password for occ user:add-app-password
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2022-03-23 18:47:33 +01:00
Joas Schilling
ab29a67a32
Allow creating app passwords without validating the user's password again
Aparently the idea behind the command was exactly to do this.

Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-03-14 13:30:59 +01:00
Joas Schilling
db1c2a5375
Merge pull request #31511 from nextcloud/bugfix/noid/allow-installing-unstable-versions
Allow installing unstable app versions based on channel and with `--allow-unstable` just like on updates
2022-03-11 14:26:30 +01:00
Joas Schilling
a4111d4846
Allow installing unstable versions
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-03-10 16:10:25 +01:00
Joas Schilling
50ccf7e2cf
Validate the password before generating an apptoken
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-03-10 15:52:01 +01:00
Joas Schilling
f98044ddce
Trigger an event to log an activity when an administrator generates an app password
Signed-off-by: Joas Schilling <coding@schilljs.com>
2022-03-10 15:25:22 +01:00
Christoph Wurst
c1000fe344
Merge pull request #31304 from nextcloud/feature/dry_run_for_add_indices
Add --dry-run option for add-missing-* cmd
2022-02-28 09:59:40 +01:00
Louis Chemineau
405c5eb813 Add --dry-run option for db:add-missing-* cmd
Signed-off-by: Louis Chemineau <louis@chmn.me>
2022-02-24 16:42:08 +01:00
Carl Schwan
db6927ee05 Improve performance when converting between DBs
Use a transaction when doing multiple inserts increase the writing
speed.

Ref: https://stackoverflow.com/a/68495887

Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-02-16 18:28:06 +01:00
Julius Härtl
415294e345
Add index for direct editing cleanup job
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-02-07 09:25:27 +01:00
Côme Chilliet
071ceff7e2
Fixes occ user:info when the user never logged in
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-01-27 16:33:24 +01:00
Côme Chilliet
b0e6a10263
Use the new function in user:setting occ command
instead of direct database queries

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-01-24 11:16:44 +01:00
Vincent Petry
14c60b10d0
Merge pull request #30275 from nextcloud/bugfix/noid/add-version-of-disabled-apps-when-available
Add version of disabled apps when available
2022-01-14 11:59:25 +01:00
Carl Schwan
6312c0df69
Check style update
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-01-13 00:19:07 +01:00
Carl Schwan
aeecb72e96
Fix a few psalm issues and moved back to psalm/phar 4.18
Signed-off-by: Carl Schwan <carl@carlschwan.eu>
2022-01-12 20:03:06 +01:00
Christoph Wurst
ed84f07784
Add missing index for propertypath only queries against properties
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-12-23 15:51:50 +01:00
Joas Schilling
a376aa6c61
Add version of disabled apps when available
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-12-15 09:08:14 +01:00
John Molakvoæ
5a766ef004
Allow to delete non-migrated previews instead of moving them
Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
2021-12-09 17:34:45 +01:00
Joas Schilling
536a812de4
Add an index for selecting the next job
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-12-01 23:57:40 +01:00
Côme Chilliet
113756db30
Fix ArrayAccess and JsonSerializable return types
First round of modifications for PHP 8.1

Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2021-11-23 09:28:56 +01:00
Christoph Wurst
781ec814e6
Do not print verbose info about app updates if there are none
This is cosmetical but if you have a large number of apps installed then
you'll see a wall of text during the server and app upgrade when it
tries to update each app via the app store. In may cases nothing will be
updated. For those boring cases we can hide the verbose info, but show
when occ is run with -v. Any actual update will still print a few lines.
Those are the important ones for the admin.

Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
2021-11-18 09:11:22 +01:00
Robin Appelman
5155f2b0c5
Merge pull request #28541 from nextcloud/path-prefix-index2
add a prefix index to filecache.path, attempt 2
2021-10-19 14:41:23 +00:00
Joas Schilling
0a812a1c09
Adjust namespace and print a message when the job was skipped
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-10-14 09:57:16 +02:00
Joas Schilling
9cd9f4b4bc
Move queries to the joblist
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-10-14 09:57:16 +02:00
Joas Schilling
e2a7482b49
Add a command to show info about a background job and force-execute it
Signed-off-by: Joas Schilling <coding@schilljs.com>
2021-10-14 09:57:16 +02:00
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>
2021-10-08 18:39:22 +02:00
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>
2021-10-08 18:38:25 +02:00
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>
2021-10-07 16:11:49 +02:00
Carl Schwan
59174cfa7c
Merge pull request #28492 from nextcloud/bugfix/occ-status
Align occ status with status.php
2021-09-30 17:45:22 +02:00