samvera-labs / fedora-migrate

Gem for migrating content to Fedora4
Other
10 stars 7 forks source link

Specify order of datastream migration #8

Open awead opened 9 years ago

awead commented 9 years ago

The order in which datastreams are migrated to new objects should be configurable. This allows required fields to be set before the object is saved.

This doesn't apply in cases where descMetadata is converted to RDF, as in Sufia's migration, but we should offer this option for non-Sufia heads.

dchandekstark commented 8 years ago

@awead I think a more general solution would be to use save(validate: false) except for the final save, if then. We have a second RDF datastream, and if it gets migrated before descMetadata, validation and hence, migration, fails.

barmintor commented 7 years ago

@awead some other things to consider- if you don't use @dchandekstark's approach, you need to somehow rebuild the cached nodes on the target to pass validation, because the rdf migration moves the statements to the parent resource. The data is there, but the validator doesn't know about it (as of AF 11).