You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We're currently running image dimensions (width/height) extraction via the FileProcessorComponent in invenio-records-resources. This is useful to "pre-calculate" the dimensions while the record is still a draft and just copy over the result on publish.
Given though that this code runs in an async Celery task right after the file upload, we have the following issues:
The task might fail
The task might run too late, i.e. if a user quickly uploads a file and publishes (e.g. using a REST API client), the task will try to calculate the dimensions and store them on the draft image metadata.
To avoid this, we can use the new RecordFilesProcessorComponent, which runs on publish and can make sure to send off a task for calculating the metadata on the published record's files.
The text was updated successfully, but these errors were encountered:
We're currently running image dimensions (width/height) extraction via the
FileProcessorComponent
ininvenio-records-resources
. This is useful to "pre-calculate" the dimensions while the record is still a draft and just copy over the result on publish.Given though that this code runs in an async Celery task right after the file upload, we have the following issues:
To avoid this, we can use the new
RecordFilesProcessorComponent
, which runs on publish and can make sure to send off a task for calculating the metadata on the published record's files.The text was updated successfully, but these errors were encountered: