Feature #13152

Add --replace or --force option to DO load task to allow uploads to replace existing digital objects

Added by Dan Gillean about 1 year ago. Updated 6 months ago.

Status:VerifiedStart date:08/13/2019
Priority:MediumDue date:
Assignee:-% Done:

100%

Category:CLI toolsEstimated time:5.00 hours
Target version:Release 2.6.0
Google Code Legacy ID: Tested version:2.6
Sponsored:Yes Requires documentation:

Description

Currently, in the digital object load task, if the task encounters a description that already has a digital object attached, it will either skip the import entirely, or create a new stub child description to attach the secondary object.

This enhancement will add a new option to the command-line task. When used, if a target description already has a digital object, the existing object will be deleted and replaced with the new object.

History

#2 Updated by Mike Cantelon about 1 year ago

  • Assignee set to Mike Cantelon

#3 Updated by Mike Cantelon about 1 year ago

  • Assignee deleted (Mike Cantelon)

#4 Updated by Steve Breker 7 months ago

Added --replace option to the digital object load task.

Notes:
  • Added the ability to have a 'slug' column instead of 'identifier' or 'information_object_id'. Column header should be 'slug' to use this feature. Note that the slug column matching is case sensitive - this is necessary if users have AtoM's 'fancy' slug generation setting turned on.
  • When a digital object is replaced, the digital object file being replaced on disk will be deleted from the uploads folder unless another digital object is referring to the same image on disk. This includes derivatives.
  • Users cannot use the '--replace' and '--attach-only' options at the same time. This will generate the error: 'Cannot use option "--attach-only" with "--replace".'
Behaviours on import:
  • If the import CSV contains one image for a specific description and the description specified in the CSV does not have a DO attached to it, this digital object will be imported and linked.
  • If the import CSV contains one image for a specific description and the description specified in the CSV already has one attached, the attached digital object will be deleted and the one specified in the CSV will be imported and linked.
  • If the import CSV contains MORE THAN ONE image for a specific description, and the description does not yet have a DO directly linked to it, the LAST IMAGE SPECIFIED IN THE CSV FOR THIS DESCRIPTION will be linked to the description.
  • If the import CSV contains MORE THAN ONE image for a specific description, and the description does already has a DO directly linked to it, the existing image will be deleted and the LAST IMAGE SPECIFIED IN THE CSV FOR THIS DESCRIPTION will be linked to the description.

#6 Updated by Steve Breker 7 months ago

  • Status changed from New to QA/Review

Merged - ready for QA.

#7 Updated by Dan Gillean 6 months ago

  • Status changed from QA/Review to Verified
  • % Done changed from 0 to 100
  • Requires documentation deleted (Yes)
  • Tested version 2.6 added

Also available in: Atom PDF