aboutsummaryrefslogtreecommitdiffstats
path: root/lib/private/Preview
Commit message (Collapse)AuthorAgeFilesLines
* Merge pull request #51355 from AIlkiv/refactor/rollback-hook-usageStephan Orbaugh2025-04-252-22/+13
|\ | | | | refactor: cleanup rollback hook usage
| * refactor: cleanup rollback hook usageailkiv2025-04-252-22/+13
| | | | | | | | Signed-off-by: ailkiv <a.ilkiv.ye@gmail.com>
* | Merge pull request #52079 from ↵Andy Scherzinger2025-04-241-4/+9
|\ \ | | | | | | | | | | | | IONOS-Productivity/fix/s3_traffic_on_video_thumbnails fix(previews): avoid large file downloads for remote movie storage
| * | fix(previews): avoid large file downloads for remote movie storageMisha M.-Kupriyanov2025-04-231-4/+9
| | | | | | | | | | | | | | | | | | | | | Prevent downloading entire movie files from remote storage (e.g., S3) when the 'moov atom' is located at the end of the file. Signed-off-by: Misha M.-Kupriyanov <kupriyanov@strato.de>
* | | refactor: Thumbnail Generator logging and testsrefactor/preview-testsnfebe2025-04-231-1/+1
|/ / | | | | | | Signed-off-by: nfebe <fenn25.fn@gmail.com>
* | feat: add logging to preview generationfeat/no-issue/add-logging-preview-generationnfebe2025-04-171-21/+27
| | | | | | | | Signed-off-by: nfebe <fenn25.fn@gmail.com>
* | fix(previews): Cleanup Movie provider code and remove deprecated static varsfix/fix-movie-preview-constructCôme Chilliet2025-04-082-45/+37
| | | | | | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* | fix(preview): Fix constructor parameter name and default valueCôme Chilliet2025-04-081-2/+2
| | | | | | | | | | | | This should fix tests for movie preview provider Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* | feat(previews): fix casing and commentsinvario2025-04-061-4/+5
| | | | | | | | | | Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com> Signed-off-by: invario <67800603+invario@users.noreply.github.com>
* | feat(previews): Clean up code for HDR video previewsinvario2025-04-031-16/+10
| | | | | | | | Signed-off-by: invario <67800603+invario@users.noreply.github.com>
* | feat(previews): Use proper colorspace and apply tonemap for HDR videosinvario2025-04-031-4/+51
|/ | | | Signed-off-by: KT <invario@gmail.com>
* fix(preview): Filter for folders in cleanup old preview jobDario Mehlich2025-01-271-7/+7
| | | | | | | | | | | | | Fixes #35936. When running `OC\Preview\BackgroundCleanupJob`, the main iteration loop in `run()` expects a folder, however, `getOldPreviewLocations()` currently does not filter by mimetype and therefore can yield a non-folder entry which causes an Exception when constructing the Folder impl. Filtering for `httpd/unix-directory`, as `getNewPreviewLocations()` already does, fixes this issue. Signed-off-by: Dario Mehlich <d.mehlich@gmail.com>
* chore(Previews): make thumbnail generation more robustjtr/preview-thumb-robustnessJosh2025-01-025-2/+37
| | | | Signed-off-by: Josh <josh.t.richards@gmail.com>
* chore(db): Correctly apply query typesGit'Fellow2024-10-171-24/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | fix: psalm fix: error fix: add batch fix: fatal error fix: add batch chore: add batch chore: add batch fix: psalm fix: typo fix: psalm fix: return bool fix: revert Manager
* fix(BackgroundJobs): Adjust intervals and time sensitivitiesprovokateurin2024-10-081-1/+2
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* chore(deps): Update nextcloud/coding-standard to v1.3.1provokateurin2024-09-193-4/+4
| | | | Signed-off-by: provokateurin <kate@provokateurin.de>
* Merge pull request #47852 from nextcloud/sharding-code-fixesJohn Molakvoæ2024-09-161-1/+0
|\
| * fix: misc code fixes around db shardingsharding-code-fixesRobin Appelman2024-09-091-1/+0
| | | | | | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* | Merge pull request #47865 from ↵Côme Chilliet2024-09-131-0/+1
|\ \ | | | | | | | | | | | | nextcloud/admin_audit/enh/move-to-event-listeners-v2 Move admin_audit to proper event listeners v2
| * | feat: Add mimetype into BeforePreviewFetchedEvent eventThomas Citharel2024-09-101-0/+1
| |/ | | | | | | Signed-off-by: Thomas Citharel <tcit@tcit.fr>
* / fix(preview): gracefully handle file not being opened in ProviderV2Richard Steinmetz2024-09-101-0/+3
|/ | | | Signed-off-by: Richard Steinmetz <richard@steinmetz.cloud>
* fix: implement sharding compatible cleanup for various bitsRobin Appelman2024-08-281-0/+57
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* style: update codestyle for coding-standard 1.2.3Daniel Kesselberg2024-08-257-12/+12
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* feat(preview): move previews for imaginary pdf to own class ImaginaryPDFernolf2024-07-252-1/+15
| | | | | | Signed-off-by: ernolf <raphael.gradenwitz@googlemail.com> Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* fix: explicitly filter for storageid in preview cleanup jobRobin Appelman2024-07-231-0/+2
| | | | Signed-off-by: Robin Appelman <robin@icewind.nl>
* feat: log file id and path when extracting the mp3 cover failsDaniel Kesselberg2024-07-041-4/+4
| | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* chore: Add SPDX headerAndy Scherzinger2024-05-2443-873/+139
| | | | Signed-off-by: Andy Scherzinger <info@andy-scherzinger.de>
* fix: Extend SVG reference checkJoas Schilling2024-05-161-1/+1
| | | | Signed-off-by: Joas Schilling <coding@schilljs.com>
* Merge pull request #44710 from nextcloud/pulsejet/imagick-check-typeJoas Schilling2024-05-1511-10/+106
|\ | | | | fix(preview): check mime type before processing with Imagick
| * fix(preview): check mime type before processing with ImagickVarun Patil2024-04-0811-10/+106
| | | | | | | | Signed-off-by: Varun Patil <varunpatil@ucla.edu>
* | fix: Fix newly spotted psalm issues, add exhaustive typed magic properties ↵Côme Chilliet2024-04-301-1/+1
|/ | | | | | for LDAP classes Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* fix: Apply new coding standard to all filesCôme Chilliet2024-04-022-2/+2
| | | | Signed-off-by: Côme Chilliet <come.chilliet@nextcloud.com>
* Lower failed movie preview to infoGit'Fellow2024-02-031-1/+1
| | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
* Merge pull request #41067 from Murena-SAS/preview-folder-deletesArthur Schiwon2024-01-181-0/+3
|\ | | | | Fix for previews not being generated sometimes
| * Check if the node has a null ID before deleting in preview watcherAkhil2023-10-231-0/+3
| | | | | | | | Signed-off-by: Akhil <akhil@e.email>
* | chore: apply changes from Nextcloud coding standards 1.1.1Joas Schilling2023-11-233-7/+7
| | | | | | | | | | Signed-off-by: Joas Schilling <coding@schilljs.com> Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
* | Merge pull request #41395 from nextcloud/hello-emfChristoph Wurst2023-11-162-25/+68
|\ \ | | | | | | feat: add preview provider for emf files based on office
| * | fix: use png as preview right awayDaniel Kesselberg2023-11-131-16/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The initial office preview implementation converted an office document with LibreOffice to PDF, used ImageMagick to extract the first page as JPEG, and passed it OC_Image. https://github.com/nextcloud/server/pull/10198 changed the implementation to use PNG rather than PDF. OC_Image can use a PNG as a preview right away, so the ImageMagick step is unnecessary. The registration code was updated to not ask ImageMagick if PDF is supported, as PDFs are no longer used to create office document previews. Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
| * | feat: allow multiple libreoffice invocationsDaniel Kesselberg2023-11-131-11/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | LibreOffice only allows one invocation per user profile.[^1] The office provider set the user profile to /tmp/owncloud-instanceid and therefore only one invocation per instance is allowed. This was introduced a while ago, yet it's unclear if this was intentionally or just a side effect.[^2] The limitation on one invocation leads to the situation that the preview generation only works for a couple of files if you upload a whole folder of emf or word files. This commit removes the limitation by using a new user profile for each preview. That's done by using instance id plus file id as postfix for getTemporaryFolder. This has some drawbacks: - Overload protection: If you upload 100 emf files, you may end up with 100 LibreOffice invocations. Though, you can use preview_concurrency_new to limit the number of previews that can be generated concurrently when php-sysvsem is available. - New profile: I assume it takes a few bits to generate a fresh LibreOffice user profile. It appears that there is no way to ask LibreOffice to not create a profile and just work with the defaults. The profile will be cleaned after use by our temp manager. - Remove the configuration option preview_office_cl_parameters: This is not strictly necessary yet, but if you set the configuration option, the generated path for the user profile is also missing. The configuration option is not well documented (e.g., it's unclear that the last option needs to be --outdir) and actually, there should be no reason to change it after all. [^1]: https://wiki.documentfoundation.org/UserProfile [^2]: https://github.com/owncloud/core/pull/9784 Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
| * | feat: add preview provider for emf files based on officeDaniel Kesselberg2023-11-131-0/+33
| | | | | | | | | | | | Signed-off-by: Daniel Kesselberg <mail@danielkesselberg.de>
* | | Us strpos() onlyGit'Fellow2023-11-151-9/+3
| | | | | | | | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
* | | Check for open_basedir before reading /procGit'Fellow2023-11-151-2/+14
|/ / | | | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
* | address reviewSimon L2023-11-031-4/+4
| | | | | | | | Signed-off-by: Simon L <szaimen@e.mail.de>
* | fix semaphore guardingSimon L2023-11-031-1/+1
| | | | | | | | Signed-off-by: Simon L <szaimen@e.mail.de>
* | Use \Throwable insteadGit'Fellow2023-11-011-1/+1
| | | | | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
* | Catch Imaginary processing errorsGit'Fellow2023-11-011-1/+1
| | | | | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
* | Don't pass invalid streams to ImaginaryGit'Fellow2023-10-251-0/+3
|/ | | | | | | | | | | | Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com> Update Imaginary.php Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com> Update Imaginary.php Signed-off-by: Git'Fellow <12234510+solracsf@users.noreply.github.com>
* also remove functionDaniel Hansson2023-10-021-19/+0
| | | Signed-off-by: Daniel Hansson <mailto@danielhansson.nu>
* Generate all preview sizes for ImaginaryDaniel Hansson2023-09-301-17/+0
| | | | | | | | | | | A follow up on https://github.com/nextcloud/server/pull/40670 Based on discussions here: https://github.com/nextcloud/server/issues/38911#issuecomment-1741819188 This fixes the case were not all previews are generated, for example in the activity view: https://github.com/nextcloud/server/issues/38911#issuecomment-1738886106 Signed-off-by: Daniel Hansson <mailto@danielhansson.nu>
* feat: Imaginary WebP supportJanisPlayer2023-09-022-1/+21
| | | | Signed-off-by: John Molakvoæ <skjnldsv@protonmail.com>