Uploaded image for project: 'iotdm'
  1. iotdm
  2. IOTDM-94

Incorrect values expected in csz attribute of AE resource

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Unresolved
    • None
    • unspecified
    • General
    • None
    • Operating System: All
      Platform: All

    • 9002

      Copied from e-mail conversation:

      In the AE resource there is a parameter contentSerialization. This is a list of ‘serializations’ defined in commonTypes as:

      <!-- auxiliary data type required to define "serializations" below -->
      <xs:simpleType name="permittedMediaTypes">
      <xs:restriction base="m2m:typeOfContent">
      <xs:enumeration value="application/xml"/>
      <xs:enumeration value="application/json"/>
      <xs:enumeration value="application/cbor"/>
      </xs:restriction>
      </xs:simpleType>

      <!-- "serializations" data type is a list of permitted media types as defined above -->
      <xs:simpleType name="serializations">
      <xs:restriction>
      <xs:simpleType>
      <xs:list itemType="m2m:permittedMediaTypes"/>
      </xs:simpleType>
      <xs:minLength value="1"/>
      </xs:restriction>
      </xs:simpleType>

      However, if I sent IoTDM Carbon the following JSON I get an error:

      Sending to:http://127.0.0.1:8282/InCSE1
      Request body...
      {
      "m2m:ae" :

      { "api" : "app-sensor", "csz" : [ "application/xml", "application/json" ], "lbl" : [ "Type/sensor", "Category/temperature" ], "rn" : "MY_SENSOR", "rr" : false }

      }

      Response body:

      {"error":"CONTENT(pc) only accept word JSON or XML for attribute csz"}

            Unassigned Unassigned
            tjanciga Tomas Janciga
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated: