ids-specification icon indicating copy to clipboard operation
ids-specification copied to clipboard

Inconsistences between schema and example files

Open IgorBalog-Eng opened this issue 11 months ago • 8 comments

While implementing new catalog classes following schema and provided example files I have discovered that there are some differences between schema and examples. Here are those differences:

https://github.com/International-Data-Spaces-Association/ids-specification/blob/main/catalog/message/schema/dataset-schema.json

Dataset

"odrl:hasPolicy": {
	"type": "array",
	"items": {
		"$ref": "https://w3id.org/dspace/schemas/2024/1/contract-schema.json#/definitions/Offer"
	},
	"minItems": 1
},

in example not as array ( "odrl:hasPolicy" : [ {):

"odrl:hasPolicy": {
    "@type": "odrl:Offer",
    "@id": "urn:uuid:2828282:3dd1add8-4d2d-569e-d634-8394a8836a88",

"Distribution": { dct:format not defined in schema

example: https://github.com/International-Data-Spaces-Association/ids-specification/blob/main/catalog/message/example/dataset.json

 "dcat:distribution": [
    {
      "@type": "dcat:Distribution",
      "dct:format": {
        "@id": "dspace:s3+push"
      },

example catalog: Catalog->dcat:dataset->dcat:distribution->"dct:format": "dspace:s3+push", vs example dataset "dct:format": { "@id": "dspace:s3+push" }

Missing: dataset->dcat:distribution->dcat:accessService->"@type": "dcat:DataService",


example catalog dcat:dataset->odrl:hasPolicy "dspace:providerId": "http://example.com/Provider", missing @id of the policy/offer

vs defined Offer object in negotiation schema https://github.com/International-Data-Spaces-Association/ids-specification/blob/main/negotiation/message/schema/contract-schema.json

Hope I managed to collect all differences for catalog and referenced objects from negotiation module. It could be also that I did not read schema files correct and this ticket is not applicable.

IgorBalog-Eng avatar Mar 11 '24 09:03 IgorBalog-Eng

Adding another one: https://github.com/International-Data-Spaces-Association/ids-specification/blob/63e5a401192336177f1d547ebd1f8e8f6f129269/negotiation/message/schema/contract-schema.json#L156 should be "odrl:target"

sebbader-sap avatar Mar 13 '24 16:03 sebbader-sap

Is this diagram still valid? There is "link" between offer and catalog https://docs.internationaldataspaces.org/ids-knowledgebase/v/dataspace-protocol/catalog/catalog.protocol#id-3.1-ack-catalog It states before A Catalog must not have an odrl:hasPolicy attribute, since it is not intended to negotiate on the access to Catalog objects.

IgorBalog-Eng avatar Mar 13 '24 16:03 IgorBalog-Eng

Adding another one:

https://github.com/International-Data-Spaces-Association/ids-specification/blob/63e5a401192336177f1d547ebd1f8e8f6f129269/negotiation/message/schema/contract-schema.json#L156

should be "odrl:target"

Already reported (but not yet fixed) in #232

schoenenberg avatar Mar 14 '24 12:03 schoenenberg

https://docs.internationaldataspaces.org/ids-knowledgebase/v/dataspace-protocol/contract-negotiation/contract.negotiation.protocol#id-2.1-contract-request-message Link to message points to offer_message not contract_request_message

IgorBalog-Eng avatar Mar 19 '24 15:03 IgorBalog-Eng

The Consumer must include an offer property, which itself must have a @id property

https://github.com/International-Data-Spaces-Association/ids-specification/blob/main/negotiation/message/example/contract-request-message.json

Where is offer.@id? Initial message contains offer.@id

--

https://github.com/International-Data-Spaces-Association/ids-specification/blob/2024-1/catalog/message/example/catalog.json Should this one also contain offer.@id in response? How will consumer know which offer.@id to send in initial_request_message?

"odrl:hasPolicy": [ { "@type": "odrl:Offer", "@id" : "missing offerId", "dspace:providerId": "http://example.com/Provider", "odrl:permission": [ {

IgorBalog-Eng avatar Mar 19 '24 15:03 IgorBalog-Eng

The example for the catalog contains a odrl:EQ: https://github.com/International-Data-Spaces-Association/ids-specification/blob/b3ff872f7b482bf1cd81de3bc554ed699be7a298/catalog/message/example/catalog.json#L49 But ODRL only has a odrl:eq, which is correctly stated in the JSON Schema.

Additionally, the distribution in this file is a JSON Object: https://github.com/International-Data-Spaces-Association/ids-specification/blob/b3ff872f7b482bf1cd81de3bc554ed699be7a298/catalog/message/example/catalog.json#L60 But the JSON Schema says it must be a JSON Array.

sebbader-sap avatar Mar 28 '24 07:03 sebbader-sap

https://github.com/International-Data-Spaces-Association/ids-specification/blob/main/negotiation/message/schema/contract-schema.json#L156 required element @target; should this one be changed with odrl:target?

IgorBalog-Eng avatar Mar 28 '24 09:03 IgorBalog-Eng

@schoenenberg @IgorBalog-Eng please check whether https://github.com/International-Data-Spaces-Association/ids-specification/pull/264 has solved your findings.

sebbader-sap avatar Jun 20 '24 08:06 sebbader-sap