Benjamin Gaussorgues
fd925b95ce
fix(perf): use index when deleting old previews
...
Signed-off-by: Benjamin Gaussorgues <benjamin.gaussorgues@nextcloud.com>
2026-02-19 13:07:15 +00:00
Robin Appelman
e0b238533f
fix: don't try to create preview folder if it already exists
...
Signed-off-by: Robin Appelman <robin@icewind.nl>
2026-02-13 14:10:59 +00:00
Carl Schwan
c844689b86
fix(preview): Fix files:app-data-scan for previews
...
And add unit tests for both migrated files and non-migrated files
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-02-12 01:54:36 +01:00
Carl Schwan
90eedeabc5
fix(preview): Handle unique constraints
...
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-02-11 19:21:12 +00:00
Carl Schwan
3facd02e51
fix(preview): Fix scanning preview
...
Make sure we set the mimetype string representation and not int
representation.
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-02-10 11:39:29 +00:00
Anna Larch
eef7422957
fix(snowflake): cast lastId to int
...
Signed-off-by: Anna Larch <anna@nextcloud.com>
2026-02-10 10:46:33 +00:00
Carl Schwan
fe2a1ce7aa
feat(preview): Make it possible to disable on preview migration
...
Signed-off-by: Carl Schwan <carlschwan@kde.org>
(cherry picked from commit 7a025ffb0b )
2026-01-28 22:36:09 +01:00
Carl Schwan
62ed106260
feat(preview): On demand preview migration
...
When requesting previews, which we don't find in oc_previews, search in
IAppData first before creating them.
Move the logic from MovepreviewJob to PreviewMigrationService and reuse
that in the Preview Generator.
At the same time rename MovePreviewJob to PreviewMigrationJob as it is a
better name.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
(cherry picked from commit 6149168129 )
2026-01-28 22:36:05 +01:00
Ferdinand Thiessen
4fba8736cf
test(preview): properly test postscript preview provider
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
2026-01-28 10:25:08 +00:00
Carl Schwan
7c1a8a4060
feat: Adapt a bit the snowflake ids API
...
- Rename setId() -> generateId() in SnowflakeAwareEntity
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-01-06 12:57:17 +01:00
Anna Larch
5f797ebc32
refactor: move existing usages of snoflake IDs SnowflakeAwareEntity
...
Signed-off-by: Anna Larch <anna@nextcloud.com>
2026-01-06 12:57:17 +01:00
Anna Larch
f546daada7
refactor: Rename Snowflake Generator and Decoder
...
And introduce the Snowflake DTO
Signed-off-by: Anna Larch <anna@nextcloud.com>
2026-01-06 12:57:04 +01:00
Carl Schwan
2ea1bd4cdc
feat(movie-preview): Use getDirectDownloadById for generating preview
...
Allow to speed-up considerably the creation of previews for movies
stored on S3.
Signed-off-by: Carl Schwan <carlschwan@kde.org>
2026-01-02 17:13:41 +01:00
invario
ffe91b48dc
feat(previews): allow ffmpeg to connect direct for AWS S3 buckets
...
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: invario <67800603+invario@users.noreply.github.com>
2026-01-02 10:48:39 +01:00
Carl Schwan
06b6a5bc05
fix(preview): Correctly insert preview version
...
Use createNamedParameter otherwise values are not correctly escapted.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-12-17 18:23:53 +01:00
Carl Schwan
247b66c5ee
fix(preview-cleanup): Also delete previews stored in the oc_previews table
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-12-10 13:49:24 +01:00
Carl Schwan
503a65ddd0
refactor: Run rector
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-11-18 17:45:54 +01:00
Carl Schwan
336cc3fa35
feat(Db): Use SnowflakeId for previews
...
Allow to get an id for the storing the preview on disk before inserting
the preview on the DB.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-28 17:50:03 +01:00
Carl Schwan
1dc363581f
fix: get all available previews on Oracle
...
Split the DB requests in chunk of 1000 and use INNER JOIN instead of IN
as this is better supported on all DB.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-23 14:10:15 +02:00
Carl Schwan
9adf6cce55
fix: Fetching previews on Oracle
...
We need an explicit cast on Oracle as Oracle returns number as string.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-23 09:39:05 +02:00
Carl Schwan
d6889e9220
fix(preview): Fix deleting dummy preview in object store
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-22 15:40:26 +02:00
Stephan Orbaugh
567a988c6c
Merge pull request #55100 from invario/previews-better-logging
...
feat(previews): improved logging for movie previews
2025-10-15 10:54:09 +02:00
invario
13500be1d1
feat(previews): improved logging for movie previews
...
Signed-off-by: invario <67800603+invario@users.noreply.github.com>
2025-10-14 13:17:09 -04:00
Carl Schwan
cb82a9ef04
refactor(preview): Cleanup a bit the public interface
...
* Remove old IProvider interface, it's been deprecated since 17.0.0 (8
years)
* Add type hinting to the IPreview interface and mark it as consumeable
only
* Remove unused arguments from GeneratorHelper
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-09 17:41:13 +02:00
Carl Schwan
fed7a33d1f
refactor(preview-object-store): Refactor object store backend
...
Simplify logic
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-08 14:07:07 +02:00
Carl Schwan
bef3996c3e
fix(preview): Make version column a string
...
And move it to a different table so that we don't have to pay the
storage cost when not using it (most of the times).
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-08 14:07:06 +02:00
Carl Schwan
66f50bd585
refactor(preview): Use same mimetype ids as filecache
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
bd001c9524
refactor: Use Override annotation in new preview code
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
58023782b6
feat(preview): Store original file mimetype in preview table
...
Allow to quickly query all the files from a specific mimetype like in
the ResetRenderedTexts command.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
bfc7d5dd9f
feat(preview): Implement scanning for previews
...
This work similarly to the move preview job to migrate the previews to
the new DB table and also reuse some code.
So when we are finding files in appdata/preview, try adding them to the
oc_previews table and delete them from the oc_filecache table.
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
324b54b863
refactor(preview): Cleanup the implementation of the new preview backend
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
6f56dcf73e
fix(preview): Fix some tests
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
b0357663b9
perf(preview): Optimize migration and simplify DB layout
...
* Simplify migration by not moving the actual files and just updating
the DB
* Don't store the storageid in the preview table as it is not needed
* Start adding tests
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
bba9667882
perf(preview): Adapt BackgroundCleanupJob to new previews table
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
6008852232
feat(preview): Support multibucket storage
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
13c35c0f17
perf(preview): Migrate previews to the new optimized table
...
Signed-off-by: Carl Schwan <carl.schwan@nextcloud.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
656e33e8da
perf(preview): Add support for multibucket storage
...
Signed-off-by: Carl Schwan <carl.schwan@nextclound.com>
2025-10-06 13:37:15 +02:00
Carl Schwan
18fbacdd8d
perf(preview): Split preview data to new table
...
The new oc_previews table is optimized for storing previews and should
decrease significantly the space taken by previews in the filecache
table.
This attend to reuse the IObjectStore abstraction over S3/Swift/Azure
but currently only support one single bucket configuration.
Signed-off-by: Carl Schwan <carl.schwan@nextclound.com>
2025-10-06 13:37:15 +02:00
invario
ba51caf5f4
Fix(previews): prevent infinite loop in case of bad video file
...
Signed-off-by: invario <67800603+invario@users.noreply.github.com>
2025-09-05 09:32:37 -04:00
invario
97a0dde160
feat(previews): previews and tests for large remote videos w/o full download
...
Co-authored-by: Kate <26026535+provokateurin@users.noreply.github.com>
Co-authored-by: Côme Chilliet <91878298+come-nc@users.noreply.github.com>
Signed-off-by: invario <67800603+invario@users.noreply.github.com>
2025-09-05 10:08:19 +02:00
provokateurin
4b2a93cf0a
chore(Preview): Remove avconv support
...
Signed-off-by: provokateurin <kate@provokateurin.de>
2025-08-27 20:51:08 +02:00
Ferdinand Thiessen
5981b7eb51
chore: apply new CSFixer rules
...
Signed-off-by: Ferdinand Thiessen <opensource@fthiessen.de>
# Conflicts:
# apps/settings/lib/SetupChecks/PhpOpcacheSetup.php
2025-07-01 16:26:50 +02:00
Arthur Schiwon
bdc68989d5
fix: unbloc ffmpeg on some broken videos
...
Co-authored-by: Joas Schilling <coding@schilljs.com>
Signed-off-by: Arthur Schiwon <blizzz@arthur-schiwon.de>
2025-05-20 22:12:13 +02:00
AndyXheli
ecd1d5dde2
fix(previews): lower log level when cached preview isn't found
...
Since this PR #52221 was implemented, the log file has been flooded with warnings stating, "Cached preview not found for file; generating a new preview." This appears to be more of an informational message rather than a warning. This PR will change it from warning to debug
Original PR
#52221
Signed-off-by: AndyXheli <andyxheli@gmail.com>
2025-05-15 07:34:40 -05:00
Louis Chemineau
867be352f3
fix(blurhash): Use preview API to generate the previews
...
This allows to benefit from all the checks done by the preview API.
This also use the newly introduced `cacheResult` argument to limit disk usage.
Signed-off-by: Louis Chemineau <louis@chmn.me>
2025-05-05 11:13:31 +02:00
Louis Chemineau
2238548278
feat(previews): Support in memory preview request
...
This allows callers to use the API without increasing the disk usage.
Example: blurhash generation, where we request a preview for all uploaded pictures, but don't want to necessarily store that preview.
Signed-off-by: Louis Chemineau <louis@chmn.me>
2025-05-05 10:38:51 +02:00
Stephan Orbaugh
258983e665
Merge pull request #51355 from AIlkiv/refactor/rollback-hook-usage
...
refactor: cleanup rollback hook usage
2025-04-25 11:42:20 +02:00
ailkiv
616716cd6a
refactor: cleanup rollback hook usage
...
Signed-off-by: ailkiv <a.ilkiv.ye@gmail.com>
2025-04-25 08:25:11 +00:00
Andy Scherzinger
34949e4a36
Merge pull request #52079 from IONOS-Productivity/fix/s3_traffic_on_video_thumbnails
...
fix(previews): avoid large file downloads for remote movie storage
2025-04-24 14:44:34 +02:00
nfebe
d980e69f74
refactor: Thumbnail Generator logging and tests
...
Signed-off-by: nfebe <fenn25.fn@gmail.com>
2025-04-23 23:06:28 +01:00