Geonovum / uml2json

Best Practise for OGC - UML to JSON Encoding Rules
https://geonovum.github.io/uml2json/document.html
0 stars 1 forks source link

Requirement requiring conformance to the JSON Schema Core spec #34

Closed heidivanparys closed 4 months ago

heidivanparys commented 1 year ago

I would expect the first requirement to be:

A JSON Schema encoding shall conform to JSON Schema: A Media Type for Describing JSON Documents.

And because of that requirement, JSON Schema: A Media Type for Describing JSON Documents becomes a normative reference (at least when following the ISO rules for when a specification is a normative reference, see also https://www.iso.org/sites/directives/current/part2/index.xhtml#_idTextAnchor193, but I believe OGC follows the same rules?).

It seems that an older specification is referenced, is that on purpose? The latest one seems to be available at the following links:

heidivanparys commented 1 year ago

Perhaps the OGC way of expressing this is to add JSON Schema: A Media Type for Describing JSON Documents, as a dependency/prerequisite? I don't know how OGC references other specifications that don't follow the modular specification.

jechterhoff commented 5 months ago

The first requirement presents a choice of which JSON Schema version is used.

The “$schema” keyword shall be added to the definitions schema. Its value shall be one of:

This allows schema generation in either format, in support of different deployment scenarios where the JSON Schema validator may or may not support one or the other JSON Schema version. The relevant IETF documents for both versions are cited as normative reference.

I know that having such options / choices is not ideal for interoperability. However, in the case of this specification, it provides flexibility for practical reasons.

If we settled on one particular version - likely 2020-12 - then we could add the according IETF documents as dependencies.

jechterhoff commented 4 months ago

Having discussed this with @PalmJanssen, we decided to remove the choice, and use the 2020-12 JSON Schema.