JiscSD / archivematica

Free and open-source digital preservation system designed to maintain standards-based, long-term access to collections of digital objects.
http://www.archivematica.org
GNU Affero General Public License v3.0
0 stars 0 forks source link

Problem: automated workflow choices for Store AIP/DIP location fail #18

Closed sevein closed 7 years ago

sevein commented 7 years ago

In #15 we added to MCPServer a new "automated" workflow: https://github.com/JiscRDSS/archivematica/commit/c8fca5a6c8305ba9b4136829f4070b113fd6f695. Two of the choices contain values that are specific to locations of a particular installation of the Storage Service:

<processingMCP>
  <preconfiguredChoices>

    <!-- Store DIP location -->
    <preconfiguredChoice>
      <appliesTo>b7a83da6-ed5a-47f7-a643-1e9f9f46e364</appliesTo>
      <goToChain>/api/v2/location/bb215be6-ce08-489a-aafb-e921bb81e72b/</goToChain>
    </preconfiguredChoice>

    <!-- Store AIP location -->
    <preconfiguredChoice>
      <appliesTo>b320ce81-9982-408a-9502-097d0daa48fa</appliesTo>
      <goToChain>/api/v2/location/0a62b8ff-ef79-4b76-8f14-a0ea7351065e/</goToChain>
    </preconfiguredChoice>

  </preconfiguredChoices>
</processingMCP>

Both bb215be6-ce08-489a-aafb-e921bb81e72b and 0a62b8ff-ef79-4b76-8f14-a0ea7351065e are UUIDs assigned to locations of a particular installation of Storage Service. Yours are different causing Archivematica to prompt the user as it happens in the default workflow.

I think we need a way to have Archivematica choosing the only location available for us. We may want to agree on a value for <goToChain> that storeAIP.py can understand as "go and pick the default location".

jhsimpson commented 7 years ago

For the MVP - we can ignore the 'store dip' choice - we shouldn't make a dip for automated workflow in MVP.

Still have to deal with the issue raised here - two ideas

1) the url /api/v2/location/0a62b8ff-ef79-4b76-8f14-a0ea7351065e/ is a storage service url - what if the storage service had a way to get the 'defaults' for a given pipeline?

see https://wiki.archivematica.org/Storage_Service_API#Get_pipeline_details We could add more data to the json response from: /api/v2/pipeline/<UUID>/

e.g., an array that listed the storage locations assigned to the pipeline or make a new REST endpoint in the ss: /api/v2/pipeline/<UUID>/locations

to do that.

2) make a new endpoint like

/api/v2/pipeline/<UUID>/locations/aip_storage/default

that is basically just a symlink to the 'default' aip storage location for that pipeline. Might require having the ss have a way to mark a location as default.

3) in the ProcessingMCP.xml, refer to the aip storage location by name rather than by a url with uuid in it. ProcessingMCP.xml used to refer to user choices by name, but that caused problems when two user inputs in different chain links had the same name.

sevein commented 7 years ago

Pull requests:

sevein commented 7 years ago

PRs merged!