Uploaded image for project: 'Olingo'
  1. Olingo
  2. OLINGO-121

Support metadata:type attribute in Entity Properties

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Major
    • Resolution: Fixed
    • V2 1.0.0
    • V2 1.1.0
    • odata2-core
    • None

    Description

      Certain OData consumers (i.e. PowerPivot for Microsfot Excel) require that the metadata:type attribute is set for all Property values in an Entry, for example:

      <entry xmlns="http://www.w3.org/2005/Atom" xmlns:m="http://schemas.microsoft.com/ado/2007/08/dataservices/metadata" xmlns:d="http://schemas.microsoft.com/ado/2007/08/dataservices" xml:base="http://localhost/odata/resourcenolinks.svc/">
      	...
      	<content type="application/xml">
      		<m:properties>
      			<d:FROM_DATE m:type="Edm.DateTime">2013-07-01T00:00:00</d:FROM_DATE>
      			<d:TO_DATE m:type="Edm.DateTime" m:null="true"/>
      			<d:IS_ACTIVE m:type="Edm.Boolean">true</d:IS_ACTIVE>
      			<d:ORGANISATION>EnergySys Support</d:ORGANISATION>
      			<d:ORDER_NUMBER m:type="Edm.Int32">2</d:ORDER_NUMBER>
      		</m:properties>
      	</content>
      </entry>
      

      The Olingo library does not specify the metadata:type attribute for properties and this means that software relying on that property can't correctly consume data generated with Olingo.

      This library should support a way to set the metadata:type attribute for properties. This could be done by allowing the producer to explicitly set the type for each property (as done in odata4j) or it could be automatically added by using the type definition in the EntityType associated with the data.

      This enhancement has been raised following discussion with Michael Boltz (see OLINGO-118 for details)

      Attachments

        Activity

          People

            chrisam Christian Amend
            Michele EnergySys M Carissimi
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: