Skip to content

Instantly share code, notes, and snippets.

@doana
Last active May 2, 2023 14:41
Show Gist options
  • Save doana/1dc9fdb53b6fdaf92f23fdac69202f6e to your computer and use it in GitHub Desktop.
Save doana/1dc9fdb53b6fdaf92f23fdac69202f6e to your computer and use it in GitHub Desktop.
DSpace config for curation in workflow
############
# CURATION #
############
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.general.NoOpCurationTask = noop
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.general.ProfileFormats = profileformats
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.general.RequiredMetadata = requiredmetadata
# plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.general.ClamScan = vscan
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.general.MicrosoftTranslator = translate
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.general.MetadataValueLinkChecker = checklinks
# UG custom curation tasks
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.ug.UGDefaultLicense = ugdefaultlicense
plugin.named.org.dspace.curate.CurationTask = org.dspace.ctask.ug.UGCollectionMapper = ugcollectionmapper
curate.ui.tasknames = profileformats = Profile Bitstream Formats
curate.ui.tasknames = requiredmetadata = Check for Required Metadata
curate.ui.tasknames = checklinks = Check Links in Metadata
# UG custom curation tasks
curate.ui.tasknames = ugdefaultlicense = Add UG default license statement
curate.ui.tasknames = ugcollectionmapper = Map ETD items to departmental collections
# curate.ui.tasknames = vscan = Virus Scan
#---------------------------------------------------------------#
#------------SUBMISSION CURATION CONFIGURATIONS-----------------#
#---------------------------------------------------------------#
# This file contains configuration properties solely relating #
# to the scheduling of curation tasks during submission -- that #
# is: when tasks are attached to a workflow. #
#---------------------------------------------------------------#
# TODO: UNSUPPORTED in DSpace 7.0
# Scan for viruses
submission-curation.virus-scan = false
# Report serializer plugin, to capture submission task reports.
# Uncomment exactly one, or configure your own.
# FileReporter writes reports to ${report.dir}/curation-yyyyMMddThhmmssSSS.report
# plugin.single.org.dspace.curate.Reporter = org.dspace.curate.FileReporter
# LogReporter writes report lines to the DSpace log.
plugin.single.org.dspace.curate.Reporter = org.dspace.curate.LogReporter
<?xml version="1.0" encoding="UTF-8" ?>
<workflow-curation xmlns='https://dspace.org/workflow-curation'>
<!-- workflow-curation assigns Curation Tasks to DSpace workflow steps. -->
<!-- The taskset-map element maps collection handles to tasksets enumerated -->
<!-- in the 'tasksets' element. The special collection handle 'default' is -->
<!-- matched when a collection is not otherwise mapped. The special -->
<!-- taskset name 'none' indicates that there is no taskset to perform. -->
<taskset-map>
<mapping collection-handle="default" taskset="ug" />
</taskset-map>
<!-- Tasksets specify curation tasks to be automatically performed at -->
<!-- specific stages of workflow. The taskset 'name' attribute should match -->
<!-- the 'taskset' attribute in the task-set mapping above. -->
<!-- Tasksets are organized into elements called 'flowsteps' which -->
<!-- correspond by name to DSpace workflow steps. Thus, to cause a task to -->
<!-- be performed in the workflow step 'edit', place a 'task' element in -->
<!-- the 'edit' flowstep. -->
<!-- -->
<!-- You may define a flowstep element in a taskset for each step in the -->
<!-- workflow, since the flowstep action occurs before its workflow step. -->
<!-- Use 'archive' for tasks to run just before the item is installed in -->
<!-- archive. -->
<!-- -->
<!-- Each flowstep also allows an optional 'queue' attribute, which -->
<!-- controls whether and where the tasks are placed on a queue for -->
<!-- deferred performance. If the attribute is not present, the tasks are -->
<!-- all performed immediately. Otherwise, the tasks are placed on a queue -->
<!-- named by the attribute value. -->
<!-- -->
<!-- You may add any number of tasks to a flowstep.-->
<!-- Each task element has a mandatory name attribute and two optional, -->
<!-- repeatable children. The task name attribute must match the plugin -->
<!-- manager name given the task in dspace.cfg. -->
<!-- -->
<!-- The 'workflow' element describes what workflow actions can be taken -->
<!-- upon completion of the task. In the example below, the vscan (virus -->
<!-- scan) task has been given the power to 'reject': meaning that if the -->
<!-- task fails - viz. a virus is detected - the item will be rejected like -->
<!-- a reviewer would reject it. -->
<!-- The other 'workflow' value is 'approve', which skips any further tasks -->
<!-- and advances the item. -->
<!-- -->
<!-- The 'notify' element allows you use the workflow system of -->
<!-- notifications (email) whenever a task is performed and returns the -->
<!-- designated status code (in the 'on' attribute): 'fail', 'success' or -->
<!-- 'error'. -->
<!-- The content of these elements must be one of the following types: -->
<!-- an eperson name, an eperson group, or one of the special literals: -->
<!-- '$flowgroup' = the workflow group of the step (if any). -->
<!-- '$colladmin' = the collection administrator's group (if any) -->
<!-- '$siteadmin' = the site administrator -->
<!-- Thus, a recap of the sample taskset below would be: run a virus scan -->
<!-- on every submitted item, reject infected submissions, notify the -->
<!-- reviewer's group and collection administrators of same, or the site -->
<!-- administrator if the task encounters an error in processing -->
<tasksets>
<taskset name="cautious">
<flowstep name="step1">
<task name="vscan">
<workflow>reject</workflow>
<notify on="fail">$flowgroup</notify>
<notify on="fail">$colladmin</notify>
<notify on="error">$siteadmin</notify>
</task>
</flowstep>
</taskset>
<taskset name="ug">
<flowstep name="archive">
<task name="ugdefaultlicense">
<notify on="error">$siteadmin</notify>
</task>
</flowstep>
</taskset>
<!-- We require an empty taskset to match "none" mappings. DO NOT REMOVE! -->
<taskset name='none'/>
</tasksets>
</workflow-curation>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment