-
Notifications
You must be signed in to change notification settings - Fork 64
More coherent image validation #5650
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
Detailed requirements (discussed with @BartChris in Marburg):
|
Sounds very good to me. The only thing i am wondering is, if the best place for the validation settings would be the kitodo_config.properties or wether we should extend the project setting screen? Extending the project setting screen is probably more (conceptual) work, especially when the settings are generally applied instance wide. |
Good Idea! May be, this was a misunderstanding on my part. |
I would prefer to make this behavior configurable via the frontend. In my opinion it's always desirable to configure options via the frontend without the need to have access to the server filesystem (I think the additional work is a good investment). |
@BartChris : do you mean the folder settings of the project? If so, I would prefer this even this feature would not be used in SLUB. This was suggest by @solth while I'm writing this answer :) We at SLUB have a strong image validation (not only file name schema even long term preservation check and a file checksum check) already since 2.x outside of Kitodo.Production implemented. I did not want this inside Kitodo.Production as the used rules got extended or changed over the time and switching to the latest release is a lot more complicated than do the validation complete outside of Kitodo.Production. Kitodo.Production is starting the validation task by executing a script and if the validation is successful this validation task is closed over the ActiveMQ API. In case that the validation was failing a few people get informed by mail over the validation error cause. Edit: Sending the answer was to early :-( I forgot: I don't know if all possible validation rules should applied to all used institutions as every institution has different rules. This made the solution inside Kitodo.Production very complex. Even if you can choose between applying different validation rules there are rules which are not covered and need checked in an other way. But as long as this rules are all optional than everyone can choose itself which one should be used or not. |
I added a first draft of an implementation in pull request #6505 including a demonstration video. You can configure rules to validate the image content of folders (file type, image size, color space, etc.). |
Is your feature request related to a problem? Please describe.
The validation of images in Kitodo should be implemented more coherently and be enhanced. What seems to be implemented are mostly checks for images which are not assigned to a structural element as part of the metadata validation
kitodo-production/Kitodo-Validation/src/main/java/org/kitodo/validation/metadata/MetadataValidation.java
Lines 121 to 122 in 5b60965
But as far as i can see, there is no real image validation implemented.
I stumbled over different problems.
WorkflowControllerService
is not checking for that attribute when the task is closed. Instead it is checking if the Task is of typetypeImagesWrite
. This is confusing.kitodo-production/Kitodo/src/main/java/org/kitodo/production/services/workflow/WorkflowControllerService.java
Lines 215 to 220 in 9826e41
This validity check has a very narrow definition of what is considered as valid. (see also Image / file name 'validation' is hardcoded to specific rules and is not used for custom configurations #5007). The validity of images has probably to include more things. For example
Is there any check for the actual file types? It seems that it is allowed right now to put TIFFs in a folder which was marked as JPEG-folder. I stumbled over that, when i mis-configured my test system and set the folder with the originals to JPEG instead of TIFFs. The system let me put TIFF files in the folder. I only noticed there was something wrong when i tried to use the "upload media" feature, uploaded Tiffs and no derivatives where created.
The text was updated successfully, but these errors were encountered: