Tuesday, 2020/04/21
10:00 am ET
Terrell Russell, Jason Coposky, Kory Draughn, Dave Fellinger, Alan King, Daniel Theunissen (Maastricht), Ton Smeele (Utrecht)
Status:
MERGED 4/15: Atomic Metadata Operations API irods/irods#4808
GOAL: Build freestanding Metalnx -> MT API -> iRODS demo
TODO: Generate 3-4 CEDAR JSON schemas for holding/testing
- https://cedar.metadatacenter.org/
- Mike has generated a first representative schema - EpigenomicsRun
- Sequencing runs
- https://openview.metadatacenter.org/templates/https:%2F%2Frepo.metadatacenter.org%2Ftemplates%2Fbd213a63-a175-4604-a2e4-085ad9ef5923
- TODO: how do we see this information/json schema without having a CEDAR login?
TODO: Update the attribute in the AVU from $id to:
- attribute: irods::metadata_template::schema
- value: https://api.myjson.com/bins/17vejk
- units: root
- Similar to protections provided by https://github.com/irods/irods_rule_engine_plugin_metadata_guard/
- https://github.com/MaastrichtUniversity/irods_avu_json-ruleset/blob/master/rules/core.py
IN PROGRESS: First draft of Swagger MT-iRODS API
- https://app.swaggerhub.com/apis/irods/metadata_templates/0.1#/info
- Should use local cached copies of metadata schemas, with local IDs
- These IDs get used/passed around, URL only stored in local representation once
- Should have CRUD on these local cached copies
- All template/schemas in the world by URL - available to be added to this system
- Local system - caches/references to external URLs, that get a local ID
- NOTE - reproduce all use cases
- GET template
- List overall available MT in the local system (pool)
- PUT template
- Add a new template to the system
- POST template
- List attached MTs on an object/collection
- POST template/add
- Attach/Apply MT to an object/collection as required/optional
- POST template/remove
- Remove MT from an object/collection
- POST template/resolve
- Resolve instance of MT based on an object/collection JSON
- POST schema/resolve
- Resolve json schema(s) that defines the metadata to be applied via template X to collection Y
- POST schema/rasterize
- Rasterize set of nested/attached schemas down into a single schema
CONSIDER: trigger on iRODS API PEPs rather than lower-level database PEPs
- this will allow control/policy for both atomic and singular metadata edit attempts
DISCUSSION: microservices should maybe grow PEPs as well? Mostly concerned with authorization issues. Could be mitigated for now with the microservices calling server_api_call, thereby going back through the PEP machinery in the server.
DISCUSSION: additional requirement may include instances of JSON to be able to refer to their controlled vocabulary that defines the elements - use of 'rel/describedby' and 'href' within each property. CEDAR doesn't currently support this, but may as the standards come into focus.
- { "$id": "http://example.com/myschema.json", "$schema": "http://json-schema.org/schema#", "type": "object", "additionalProperties": false, "properties": { "links": { "type": "array", "minItems": 1, "maxItems": 1, "items": { "type": "object", "additionalProperties": false, "required": [ "rel", "href" ], "properties": { "rel": { "const": "describedby" }, "href": { "const": "http://example.com/myschema.json" } }}}, "title": { "type": "string" }, "parameters": { "type": "object", "additionalProperties": false, "properties": { "size": { "type": "number" }, "readOnly": { "type": "boolean" } }}, "authors": { "type": "array", "items": { "type": "string" } }, "references": { "type": "array", "items": { "type": "object", "additionalProperties": false, "properties": { "title": { "type": "string" }, "doi": { "type": "string" } }}}}}
- { "links": [ { "rel": "describedby", "href": "http://example.com/myschema.json", } ], "title": "Hello World!", "parameters": { "size": 42, "readOnly": false }, "authors": [ "Foo", "Bar" ], "references": [ { "title": "The Rule Engine", "doi": "1234.5678" } ] }
- JSON Schema specifies that a metadata template reference can optionally be included in a JSON structure as a Linked Description Object (LDO) 5 through the linked data protocol using a ”describedby” relationship [7]. For the purpose of validation, we will require the LDO to be included in each namespace. As a result, when the JSON structure is converted to corresponding AVUs, the resulting set will always include AVU information with the LDO that provides a reference to the ruling metadata template for this namespace. This method ensures that the ruling metadata template for a namespace is registered with the iRODS object