IQSS/9506 thumbnail failure tracking and other performance improvements#9669
Merged
pdurbin merged 47 commits intoIQSS:developfrom Dec 5, 2023
Merged
Conversation
Contributor
|
Thank you so much @qqmyers for implementing it, this will solve the slow page load issue for us and anyone using custom S3 endpoints. |
sekmiller
approved these changes
Nov 28, 2023
Contributor
sekmiller
left a comment
There was a problem hiding this comment.
Looks good. thanks for the updates.
This matches previewimageavailable, also in dvobject. Plus it's clear we aren't talking about shaving. :)
This should have been part of 4ad06ba.
pdurbin
reviewed
Dec 4, 2023
src/main/java/edu/harvard/iq/dataverse/search/SearchIncludeFragment.java
Show resolved
Hide resolved
qqmyers
added a commit
to QualitativeDataRepository/dataverse
that referenced
this pull request
Dec 5, 2023
FWIW: QDR generates a 400px version here and then uses styling to fit the page. Not sure what the motivation for that was without digging.
Member
|
There are merge conflicts and the SQL script needs to be bumped. |
IQSS/9506-thumbnail-tracking
Conflicts (easy, just "add both"): doc/sphinx-guides/source/api/changelog.rst doc/sphinx-guides/source/api/native-api.rst src/main/java/edu/harvard/iq/dataverse/api/Admin.java
Member
|
Found a regression, which Jim fixed (thank you!). I confirmed that I can still generate thumbnails for images and PDFs. For PDFs I had to install ImageMagick. See also this issue: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What this PR does / why we need it: This PR makes several changes to improve the performance of thumbnail generation and retrieval, covering the issue #9506 (also reported via QDR) and the issue raised by Bikramjit Singh/Borealis when using relatively slow S3 storage (email between Borealis and @scolapasta, @pdurbin and @qqmyers ) and additional issues discovered while investigating:
previewshavefailedpreviewimagefail flag that is set the first time an attempt to create a thumbnail for a given file fails which is then used to avoid retrying the thumbnail creation process every time a thumbnail is requested (or isThumbnailAvailable() was called). Adds api calls to reset this flag globally or per file (to allow retrying)Which issue(s) this PR closes:
Special notes for your reviewer:
This PR doesn't completely remove using a base64 encoded thumb URL, e.g. on the dataset and file page where one base64 image is displayed. Once could also remove it in that case, but the performance issues related to base64 generation are primarily when many images have to be created before a page can be rendered.
This may also be useful for the SPA?
Suggestions on how to test this: Assure that thumbnails appear for image/pdf files as before (regression), that initial page load is faster/DV server is not making multiple S3 calls from the server to render initial root collection page, that files where thumbnail generation fails get marked with the previewshavefailed flag and subsequent accesses don't attempt to recreate the thumbnail, that using the api call to reset the flag for a/all files results in a new attempt to create a thumbnail.
Does this PR introduce a user interface change? If mockups are available, please link/include them here: thumbnails on the main page now load ~asynchronously (versus the page not loading at all until all thumbs are available).
Is there a release notes update needed for this change?:
Additional documentation: admin API docs