Derivative infrastructure switch (remove iiif_print, move towards custom derivatives)#59
Merged
Merged
Conversation
Contributor
|
Noticing this error in the logs starting up: |
Collaborator
Author
@dolsysmith I just pushed a commit that I think should fix this. Can you pull and see if you still hit the same issue? |
dolsysmith
approved these changes
Feb 20, 2026
dolsysmith
left a comment
Contributor
There was a problem hiding this comment.
Looks good! Nice work!
Collaborator
Author
|
Great! I'll go ahead and merge and will hold off on finishing up the custom derivative processes until we get all the other branches reconciled. |
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 type of PR is this? (check all applicable)
Description
What did you change and why?
This PR accomplishes two main things:
Removes iiif_print infrastructure - getting this gem to work well with the version of Hyrax we are running is possible, but involved a large number of customizations to the Hyrax code, and the strategy for preparing documents for OCR search and rendering in Universal Viewer (the 'derivative rodeo') creates an object in Fedora for each page of a document, which ends up complicating infrastructure in some odd ways.
Sets up the framework for creating custom derivative generation process we're moving towards, partially inspired by processes from iiif_print and the derivative rodeo, but in a pattern that I think is going to be easier to maintain and less obfuscated. This is done by using the HyraxListener and listening for 'on_object_deposited' events, identifying events that apply to the deposited work, and then using that to trigger a 'create_representative_derivatives' job, which in turn will trigger the other jobs for custom derivative creation and attachment of service files to works. A basic frame of this is included in DerivativeServices::WorkImagesToPdfDerivativesService, and the implementation will come in a future PR - largely will be a tidied up version of the process shown in our team meeting two weeks ago. At the moment, this raises and catches an error and successfully triggers a retry of the job, with incrementally increasing time between retries.
IMPORTANT: At the moment, this is not actually creating the supplemental derivatives and intentionally short circuiting in the HyraxListener
QA Instructions, Screenshots, Recordings
Build docker images, start containers, exec into rails container and run
bundle exec rspec- should be 202 examples, 0 failures, 1 pending.Added/updated tests?
[optional] Are there any post deployment tasks we need to perform?