Tif-Validation

This step plugin allows you to validate images using JHove and customize the workflow

Overview

Introduction

This plugin is used to validate images in TIF format within defined directories. The validation is done with the help of the open source software library JHove and is extensively configurable.

Installation

To install the plugin, the following file must be installed first:

/opt/digiverso/goobi/plugins/step/plugin_intranda_step_tif_validation-base.jar

To configure how the plugin should behave, different values can be adjusted in the configuration file. The central configuration file is usually located here:

/opt/digiverso/goobi/config/plugin_intranda_step_tif_validation.xml

Within this configuration file the path to the JHove configuration is named. In the case of the example below, the following path is given:

<jhoveConfiguration>/opt/digiverso/goobi/config/jhove/jhove.conf</jhoveConfiguration>

Accordingly, the following two files must also be installed under this path:

/opt/digiverso/goobi/config/jhove/jhove.conf
/opt/digiverso/goobi/config/jhove/jhoveConfig.xsd

Overview and functionality

The plugin is usually executed fully automatically within the workflow. It first determines whether there is a block within the configuration file that has been configured for the current workflow with respect to project name and work step. If this is the case, the other parameters are evaluated and the checks are started. If one of the configured checks is not successful, the configured or alternatively the previous work step is set to an error status and the validation message is written to the process log. If the work steps between the validation step and the notified step are to be set in the status to closed, these steps are also provided with the correction message for the agents and thus allow the problem case to be traced.

This plugin is integrated into the workflow in such a way that it is executed automatically. Manual interaction with the plugin is not necessary. For use within a step of the workflow it should be configured as shown in the following screenshot.

Configuration

The configuration for the plugin is done within the central configuration file. It looks like the following example:

<config_plugin>
    <config>
        <project>*</project>
        <step>*</step>
        <!-- folders to validate, can be multiple one (e.g. master, main etc. -->
        <folder>master</folder>
        <openStepOnError>Scanning</openStepOnError>
        <lockAllStepsBetween>true</lockAllStepsBetween>
        <jhoveConfiguration>/opt/digiverso/goobi/config/jhove/jhove.conf</jhoveConfiguration>
        <namespace uri="http://www.loc.gov/mix/v20" name="mix" />
        <namespace uri="http://hul.harvard.edu/ois/xml/ns/jhove" name="jhove" />
        <!--Counter check -->
        <check>
            <xpath>count(//jhove:repInfo/jhove:format)</xpath>
            <wanted>1.0</wanted>
            <error_message>Check for image format count: Image: "${image}" Wanted value: "${wanted}"\, found value: "${found}".</error_message>
        </check>
        <check>
            <xpath>string(//jhove:repInfo/jhove:format)</xpath>
            <wanted>TIFF</wanted>
            <error_message> Check for image format: Image: "${image}" Wanted value: "${wanted}"\, found value: "${found}".</error_message>
        </check>
        <!--Check if the image is well-formed and valid -->
        <check>
            <xpath>//jhove:repInfo/jhove:status</xpath>
            <wanted>Well-Formed and valid</wanted>
            <error_message> Check for image status: Image: "${image}" Wanted value: "${wanted}"\, found value: "${found}".</error_message>
        </check>
        <!--Check for resolution (number or range) -->
        <integrated_check name="resolution_check">
            <mix_uri>http://www.loc.gov/mix/v20</mix_uri>
            <wanted>100.0-899.23</wanted>
            <error_message> Check for resolution: Image: "${image}" Wanted value: "${wanted}"\, found value: "${found}".</error_message>
        </integrated_check>
    </config>
</config_plugin>

The parameters within the plugin's central configuration file have the following meanings:

Last updated