opendatamesh-initiative / odm-specification-dpdescriptor

The Data Product Descriptor Specification (DPDS) Repository
https://dpds.opendatamesh.org/
Apache License 2.0
67 stars 2 forks source link

Add `mediaType` attribute to `Reference Object` #31

Closed andrea-gioia closed 3 months ago

andrea-gioia commented 4 months ago

Add mediaType attribute to Reference Object

Champion: @andrea-gioia

Summary

Add mediaType attribute to Reference Object

Motivation

We need the mediaType attribute to referentiating external resources with an encoding different from the one of the root entity of the descriptor file

Design and examples

Field Name Type Description
description string A description which by default SHOULD override that of the referenced component. CommonMark syntax MAY be used for rich text representation. If the referenced object type does not allow a description field, then this field has no effect.
mediaType string The media type of the referenced resource. It must conform to media type format, according to RFC6838.
$ref string:uri-reference REQUIRED. The reference identifier. This MUST be in the form of a URI.

Alternatives

Add mediaType attribute to Reference Object and at the same time remove External Reference Object. Reference Object can then be used to resolve all the references, internal end external as well.

Decision

We decided to add mediaType attribute to Reference Object and keep External Reference Object to differentiate clearly internal references that should be evaluated by external tools from external references that can be ignored.

Consequences

NA

References

NA