Project

General

Profile

Task #364

Story #589: modify metacat native interfaces to support arbitrary identifiers and system metadata

refactor handleInsertOrUpdateAction() to support GUIDs

Added by Matthew Jones about 14 years ago. Updated about 13 years ago.

Status:
Closed
Priority:
High
Assignee:
Category:
Metacat
Target version:
Start date:
Due date:
% Done:

100%

Milestone:
CCI-0.6
Product Version:
*
Story Points:
Sprint:

Description

Accept GUIDs on insert and update operations using GUIDs by first generating a LocalID with the appropriate semantics and then completing the insertion using that LocalID. If the operation is an update, be sure to create the LocalID as a new rev of the original LocalID.

History

#1 Updated by Matthew Jones about 14 years ago

Refactored ResourceHandler.putObject() to take a global identifier (guid) on input rather than a localId. The method now calls IdentifierManager.generateLocalId() to create a metacat-conformant local identifier, which is used for the insert or update. So now arbitrary string identifiers can be used through the Metacat Rest interface. Still need to handle update semantics, but this depends upon changing the putObject method to identify the old object that is being updated so that an appropriate new identifier can be used by incrementing the revision. Also need to expose exception data and http error codes to the client, but this depends on exceptions being better specified. So, that work on exceptions should be tackled under the create() and update() bugs for MN 0.3, rather than here.

#2 Updated by Matthew Jones about 14 years ago

Partially refactored REST interface to separate create() and update() methods, rather than having a single putObject() method. More refactoring to be done before support for arbitrary identifiers in update() can be completed.

#3 Updated by Matthew Jones over 13 years ago

  • Milestone set to CCI-0.6
  • Target version deleted (CCI-1.0)
  • Parent task set to #589

#4 Updated by Chris Jones about 13 years ago

  • Status changed from New to In Progress

#5 Updated by Chris Jones about 13 years ago

  • Assignee changed from Matthew Jones to Chris Jones

#6 Updated by Chris Jones about 13 years ago

  • Status changed from In Progress to Closed

Modified MetacatHandler to create GUIDs on insert or update via clients that don't support the DataONE CRUD API. System metadata fields are also created (or updated), and object format information is pulled from science metadata (EML only for now). Changes were largely in handleInsertOrUpdateAction(), along with the addition of a few supporting methods (read(), readFromFilesystem(), insertOrUpdateSystemMetadata()). Code in metacat should be refactored to not write to disk in order to get InputStreams.

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 14.8 MB)