aboutsummaryrefslogtreecommitdiffstats
path: root/tests/lib/Files/ObjectStore
Commit message (Collapse)AuthorAgeFilesLines
* fix: Harden files scanner for invalid null accessbackport/50436/stable31Ferdinand Thiessen2025-01-281-5/+2
| | | | | | Co-authored-by: Ferdinand Thiessen <opensource@fthiessen.de> Co-authored-by: Kate <26026535+provokateurin@users.noreply.github.com> Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* chore(deps): Update nextcloud/coding-standard to v1.3.1provokateurin2024-09-191-2/+2
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* test: fix incorrect ltrim usage in testRobin Appelman2024-09-181-2/+2
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* fix(tests): Fix most obvious errors in ObjectStore testsCôme Chilliet2024-09-172-0/+4
| | | | | | Some are still failing Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* perf(ObjectStoreStorage): Improve (slow) move on same object bucketChristoph Fiehe2024-09-162-0/+70
| | | | | | | | | This commit fixes the issue #47856. When you upload a file into a group folder and when you use a single S3 bucket as primary storage, the final move operation hangs for a long time. In the background, Nextcloud initiates a copy-delete sequence from the bucket into the bucket, with causes a lot unnecessary overhead. Nextcloud thinks that the file must be imported to another storage and does not recognize that everything is done on the same object bucket. In that case, the import step can be completely skipped, which saves time, network bandwidth and reduces the load on the object storage. The behavior improves a lot with https://github.com/nextcloud/server/pull/46013. However, there are still some put messages that are being sent to the object storage when you use an object storage as primary storage and upload files into a group folder. Co-authored-by: Kate <26026535+provokateurin@users.noreply.github.com> Signed-off-by: Christoph Fiehe <c.fiehe@eurodata.de>
* refactor: Add void return type to PHPUnit test methodsChristoph Wurst2024-09-157-29/+29
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* style: update codestyle for coding-standard 1.2.3Daniel Kesselberg2024-08-251-1/+1
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* ci: Skip flaky test on PHP 8.3Joas Schilling2024-08-211-0/+4
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* chore: Add SPDX headerAndy Scherzinger2024-05-1311-177/+25
| | | | Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
* fix: Apply new coding standard to all filesCôme Chilliet2024-04-023-3/+3
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* refactor(objectstorage): cleanup typesThomas Citharel2024-02-021-2/+2
| | | | Signed-off-by: Thomas Citharel <tcit@tcit.fr>
* fix(tests): Add messages to assertions to explain what failedJoas Schilling2024-01-261-8/+8
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* chore(tests): Migrate object storage unit tests from drone to GitHub ActionsFerdinand Thiessen2024-01-261-0/+4
| | | | Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* fix(tests): Fix deprecation errors in S3 testsFerdinand Thiessen2024-01-261-1/+2
| | | | Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* fix(ObjectStore): Make copying behavior consistent with local storageFerdinand Thiessen2023-11-171-0/+38
| | | | | | Drop file permissions on copy like we do on local storage. Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
* repair -1 folder sizes for object store background scanRobin Appelman2023-05-101-16/+26
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* composer run cs:fixCôme Chilliet2023-01-202-2/+0
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* test disabling write checkRobin Appelman2022-10-262-0/+13
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* fix using FSEEK_END with SeekableHttpStream to get file sizeRobin Appelman2022-09-152-0/+19
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* store unencrypted size in the unencrypted_size columnRobin Appelman2022-08-161-1/+1
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Check style updateCarl Schwan2022-01-131-2/+2
| | | | Signed-off-by: Carl Schwan <carl@carlschwan.eu>
* Implement multibucket shift for ObjectStoreJohn Molakvoæ2021-11-111-11/+35
| | | | Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>
* Refactor writeObject to only use MultipartUpload when requiredBernd Rederlechner2021-08-202-0/+105
| | | | | | Signed-off-by: Bernd Rederlechner <Bernd.Rederlechner@t-systems.com> Co-authored-by: Julius Härtl <jus@bitgrid.net>
* Run s3 tests againJulius Härtl2021-06-301-6/+1
| | | | Signed-off-by: Julius Härtl <jus@bitgrid.net>
* set mimetype for objects uploaded to object storagesRobin Appelman2021-04-213-4/+4
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* apply object store copy optimization when 'cross storage' copy is within the ↵Robin Appelman2021-03-091-0/+24
| | | | | | same object store Signed-off-by: Robin Appelman <robin@icewind.nl>
* use in objectstore copyRobin Appelman2020-11-243-0/+24
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Add visibility to all methods and position of static keywordChristoph Wurst2020-04-102-4/+4
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Format control structures, classes, methods and functionChristoph Wurst2020-04-104-4/+0
| | | | | | | | | | | | | | | 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>
* Use a blank line after the opening tagChristoph Wurst2020-04-093-3/+9
| | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Use exactly one empty line after the namespace declarationChristoph Wurst2020-04-092-2/+0
| | | | | | For PSR2 Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* add basic tests for s3 seeking and add some error handling if reopen return ↵Robin Appelman2020-04-012-4/+20
| | | | | | the wrong range Signed-off-by: Robin Appelman <robin@icewind.nl>
* Merge pull request #20170 from nextcloud/techdebt/remove-unused-importsChristoph Wurst2020-03-271-1/+0
|\ | | | | Remove unused imports
| * Remove unused importsChristoph Wurst2020-03-251-1/+0
| | | | | | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* | Use the short array syntax, everywhereChristoph Wurst2020-03-262-5/+5
|/ | | | Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
* Make phpunit8 compatibleRoeland Jago Douma2019-11-272-3/+3
| | | | Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* Some php-cs fixesRoeland Jago Douma2019-11-223-1/+2
| | | | | | | | | | | * Order the imports * No leading slash on imports * Empty line before namespace * One line per import * Empty after imports * Emmpty line at bottom of file Signed-off-by: Roeland Jago Douma <roeland@famdouma.nl>
* dont delete cache entries if deleting an object from object store failedRobin Appelman2019-09-252-0/+79
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* always use multipart uploader for s3 uploadsRobin Appelman2019-01-281-3/+28
| | | | | | the multipart uploader handles non seekable streams while `upload` does not Signed-off-by: Robin Appelman <robin@icewind.nl>
* upload new files in objectstore to a .part path firstRobin Appelman2018-12-123-1/+107
| | | | | | | | This prevent the object store and cache from getting out of sync when an objectstore silently fails or the php process get's killed during the upload without giving us the chance to cleanup Signed-off-by: Robin Appelman <robin@icewind.nl>
* Add objectExists to objectstore interfaceRobin Appelman2018-12-121-0/+15
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Moves the logo files to logoMichael Weimann2018-10-021-1/+1
| | | | Signed-off-by: Michael Weimann <mail@michael-weimann.eu>
* add azure unit tests with azuriteRobin Appelman2018-06-041-0/+38
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* add ci for swift primary storageRobin Appelman2018-02-081-0/+3
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Use S3Client::upload instead of splitting single/multipart upload ourselvesRobin Appelman2018-01-241-5/+12
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Add tests for multipart uploadRobin Appelman2017-09-211-4/+17
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* add ci support for s3 object storeRobin Appelman2017-01-021-0/+3
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* add amazon s3 objectstore backendRobin Appelman2016-11-161-0/+38
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* split testing of objectstoragestorage and objectstore implementationsRobin Appelman2016-11-164-177/+319
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* Allow setting a maximun number of buckets for multibucketRobin Appelman2016-11-021-5/+9
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>