sul-dlss / dor-services-app

A Rails application exposing Digital Object Registry functions as a RESTful HTTP API

Home Page:https://sul-dlss.github.io/dor-services-app/

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Use cocina structural diff to determine files to send to purl-fetcher

justinlittman opened this issue · comments

Currently, the files to send to purl-fetcher are determined based on the existing content diffing strategy: https://github.com/sul-dlss/dor-services-app/blob/main/app/services/shelving_service.rb#L50

For this ticket, implement a new strategy that compares the current cocina structural against the cocina structural retrieved from purl (https://purl.stanford.edu/.json). For any file which is (1) shelved and (2) not in purl cocina or in purl cocina but has different checksums, send to purl-fetcher.

Note that this is only for shelving via purl-fetcher. Shelving via file copy (DigitalStacksService) should remain the same.