Robin Appelman
936f634069
Merge pull request #36643 from nextcloud/fs-setup-instrimuntion
...
more filesystem setup performance instrumentation
2023-02-13 14:37:57 +07:00
Robin Appelman
91d5f6a826
more filesystem setup performance instrumentation
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-02-10 11:11:13 +07:00
Julius Härtl
d9cd8b1d37
Merge pull request #36610 from nextcloud/folder-lazy-submounts
2023-02-10 09:09:08 +07:00
Robin Appelman
5bcf37b7ff
only fetch the data for mounts inside a folder when needed
...
for most operations we don't actually care about any mounts inside a folder, only for metadata that needs to propagate across storage boundaries (size, etag, mtime) do we need all the submount info.
By only loading this data when needed we can save a bunch of storage setup in a number of cases
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-02-09 11:39:00 +07:00
Julius Härtl
08802ad13f
Merge pull request #36566 from nextcloud/mount-find-by-numeric-id
2023-02-08 20:04:57 +07:00
Robin Appelman
9f3dbb699a
fix tests
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-02-07 15:50:10 +07:00
Côme Chilliet
308fcf4526
Respect OCP interface in private classes
...
Because the parameter type was moved to phpdoc it needs to be removed
from implementations
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:35 +07:00
Côme Chilliet
028c225d96
Fix psalm errors
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:32 +07:00
Côme Chilliet
cd885b5705
Type sizes as int|float throughout the code base
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:31 +07:00
Côme Chilliet
5c1a0e0307
Allow float sizes in FileInfo for 32bits
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:31 +07:00
Côme Chilliet
d9dbed9105
Fix psalm errors related to filesizes
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:29 +07:00
Côme Chilliet
ff776a90b1
Strong type filesize related methods to ease 32bits problem findings
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:28 +07:00
Côme Chilliet
e156f8339c
Revert "remove 32-bit workarounds"
...
This reverts commit dd8774389e .
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-02-07 11:23:28 +07:00
Robin Appelman
e3bafcc7a8
cache numeric id in mountpoint
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-02-06 18:20:08 +07:00
Robin Appelman
9281359fa4
deduplicate getStorage() logic in Mount\Manager
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-02-06 18:17:40 +07:00
Robin Appelman
43589312cc
dont delegate Mount\Manager::getByNumericId to getByStorageId
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-02-06 18:16:23 +07:00
Joas Schilling
4bdc5834fa
Make sure name and path are strings
...
Otherwise Oracle returns NULL for empty strings and PHP 8.2
throws on null in string functions like trim() and md5()
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-02-02 12:05:22 +07:00
Joas Schilling
c27c9fac98
Try fixing Oracle
...
Signed-off-by: Joas Schilling <coding@schilljs.com>
2023-02-02 12:05:21 +07:00
Richard Steinmetz
f0a3b77d0f
fix(encryption): don't throw on missing file
...
Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
2023-01-30 10:07:01 +07:00
Vincent Petry
9ecec2fd75
Merge pull request #35894 from nextcloud/move-from-encryption
...
fix moving files of encrypted local storage to unencrypted local storage
2023-01-26 09:45:12 +07:00
Julius Härtl
919a840f34
Merge pull request #32798 from nextcloud/enh/sse-c
...
[S3] Add option to specify an SSE-C customer provided key
2023-01-25 15:59:26 +07:00
Robin Appelman
33b90d28f8
fix moving files of encrypted local storage to unencrypted local storage
...
for example when moving encrypted files to a groupfolder
Signed-off-by: Robin Appelman <robin@icewind.nl>
2023-01-24 16:40:41 +07:00
Thomas Citharel
00d9d49303
Add app config for default template path
...
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2023-01-24 09:39:31 +07:00
Julius Härtl
159a0c8411
feat(s3): Add option to specify an SSE-C customer provided key
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2023-01-24 10:36:03 +07:00
Côme Chilliet
f5c361cf44
composer run cs:fix
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-01-20 11:45:08 +07:00
Côme Chilliet
5e090d044d
Merge pull request #36075 from fmenabe/s3-storage-class
...
Add support for s3 storage classes
2023-01-16 09:43:53 +07:00
François Ménabé
cf9bdc0274
Manage s3 storage class in objectstore
...
Signed-off-by: François Ménabé <francois.menabe@gmail.com>
2023-01-12 14:58:27 +07:00
Git'Fellow
e855298b3c
Switch logical operators
...
Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
2023-01-11 16:27:33 +07:00
Côme Chilliet
a7740c0ae6
Suppress last psalm error until upstream fix is released and included
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-01-02 15:17:38 +07:00
Côme Chilliet
a372564850
Fix psalm spotted errors with new requirements
...
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2023-01-02 15:02:28 +07:00
Vincent Petry
3bcbc4701a
Merge pull request #34724 from nextcloud/encryption-read-before-cache
...
fix reading newly written encrypted files before their cache entry is written
2022-12-20 17:16:12 +07:00
Vincent Petry
3b7cc31f64
Merge pull request #34924 from nextcloud/cache-jail-path-prefix
...
escape path prefix when doing cache jail search
2022-12-16 17:27:15 +07:00
Julius Härtl
59ae6e9dd6
Also update the unencrypted size of files when creating them with empty content
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-12-07 19:12:06 +07:00
Julius Härtl
77edd36583
Update the unencrypted file size when closing streams
...
Signed-off-by: Julius Härtl <jus@bitgrid.net>
2022-12-07 16:26:31 +07:00
Simon L
2e0d262864
Merge pull request #35576 from nextcloud/handle-possible-null-value-in-new-simple-file
...
Handle possible null value for file in OC\Files\SimpleFS\NewSimpleFile
2022-12-06 19:52:55 +07:00
Thomas Citharel
a5b6119ec4
Handle possible null value for file in OC\Files\SimpleFS\NewSimpleFile
...
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
2022-12-03 17:25:32 +07:00
Maxence Lange
cc639a8877
compare cached filesize on download
...
Signed-off-by: Maxence Lange <maxence@artificial-owl.com>
2022-12-01 15:42:15 +07:00
Robin Appelman
e3a0e64698
clear is-encrypted cache when trying to fix encrypted version
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-12-01 14:36:27 +07:00
Robin Appelman
e9b87c73fa
fix reading newly written encrypted files before their cache entry is written
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-30 14:54:56 +07:00
Andy Xheli
e69c7c4d26
Fix Executing a query: SQLSTATE[42000]
...
Signed-off-by: Andy Xheli <axheli@axtsolutions.com>
Fix https://github.com/nextcloud/server/issues/32007#issuecomment-1329405245
Signed-off-by: Andy Xheli <axheli@axtsolutions.com>
2022-11-29 11:24:56 +07:00
Louis Chemineau
66ba90ceff
Update cache when file size === 0
...
The conditions were false when $result === 0.
$results here contains the number of written bits.
The correct way of checking for operation success is to check if $result === false
Signed-off-by: Louis Chemineau <louis@chmn.me>
2022-11-23 12:43:57 +07:00
Robin Appelman
841a6a084e
delay updating setup providers untill we register the mounts
...
otherwise the fallback to a full setup for a missing cached mount provider will lead to a race condition
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-17 15:21:57 +07:00
Simon L
9d45845d2a
Merge pull request #34994 from Glandos/fileinfo_perf
...
[Performance] Test valid path only if file info has to be retrieved
2022-11-11 17:11:21 +07:00
Côme Chilliet
a78595a45f
Make sure that path is normalized and then checked,
...
and not the other way around
Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
2022-11-10 15:03:15 +07:00
Glandos
48ca33761f
Test valid path only if file info has to be retrieved
...
Signed-off-by: Glandos <bugs-github@antipoul.fr>
2022-11-06 19:23:53 +07:00
Robin Appelman
f76b4473ee
escape path prefix when doing cache jail search
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-11-02 12:44:51 +07:00
szaimen
3f7c620f26
fix psalm
...
Signed-off-by: szaimen <szaimen@e.mail.de>
2022-11-02 11:13:34 +07:00
szaimen
dd8774389e
remove 32-bit workarounds
...
Signed-off-by: szaimen <szaimen@e.mail.de>
2022-11-02 11:13:34 +07:00
Robin Appelman
a5036a973c
allow disabling object store write check
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2022-10-26 18:45:59 +07:00
Vincent Petry
4aa8e80511
Merge pull request #34579 from nextcloud/unencrypted-size-null
...
fix null error in getUnencryptedSize
2022-10-21 16:53:43 +07:00