Details

    • Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: V4.0_WD01
    • Fix Version/s: V4.0_WD01
    • Labels:
      None
    • Environment:

      [Applied]

      Description

      Instead of a monolithic XML metadata document the metadata could be made available as an OData service with a fixed schema:

      Entity types

      • EntitySet
      • EntityType
      • Property
      • Annotation
      • ...

      Entity sets

      • EntitySets
      • EntityTypes
      • Properties
      • Annotations
      • ...

      This meta-service could be accessed via a canonical URL, ideally ~/$metadata/ with $format=atom/json or a corresponding Accept header.

      This would allow accessing only parts of the metadata document the client is interested in and simplify parsing for clients: they only need to know how to interpret "normal" OData feed and entity response payloads without needing a separate metadata format.

      It would also conveniently provide a JSON format for metadata.

      Accepted: https://www.oasis-open.org/committees/download.php/48097/odata-meeting-23_on-20130130_31-F2F-minutes.html#odata-126

        Attachments

          Activity

          Hide
          mikep Michael Pizzo (Inactive) added a comment -

          There have been a lot of requests for this in the past, but we need a full proposal (including CSDL of the metadata document) to understand design details and provide sufficient direction to the editors. This might be good to add to the issues to work on at the November Face to Face.

          Show
          mikep Michael Pizzo (Inactive) added a comment - There have been a lot of requests for this in the past, but we need a full proposal (including CSDL of the metadata document) to understand design details and provide sufficient direction to the editors. This might be good to add to the issues to work on at the November Face to Face.
          Hide
          ralfhandl Ralf Handl added a comment -

          The current model (picture and edmx) are checked into SVN:

          ToDo:

          • Convert Edmx to V4 format (could someone write an XSL translation for that?)
          • Transform entity types AnnotationsElement and ParameterType into complex types and targeting navigation properties into complex properties
          • Add Documentation complex property type to all approprioate entity types

          Feedback is highly welcome!

          Show
          ralfhandl Ralf Handl added a comment - The current model (picture and edmx) are checked into SVN: https://tools.oasis-open.org/version-control/browse/wsvn/odata/trunk/spec/examples/MetadataService/MetaModel.edmx?sc=1 (V3 format https://tools.oasis-open.org/version-control/browse/wsvn/odata/trunk/spec/examples/MetadataService/EntityDesignerDiagram.png?op=dl&rev=0&isdir=0 ToDo: Convert Edmx to V4 format (could someone write an XSL translation for that?) Transform entity types AnnotationsElement and ParameterType into complex types and targeting navigation properties into complex properties Add Documentation complex property type to all approprioate entity types Feedback is highly welcome!
          Hide
          sdrees Stefan Drees (Inactive) added a comment -

          Is there a mapping to base a transform for the MetaModel.edmx transition from v3 to v4 upon?
          I'ld be willing to act on the first item in the above todo lit (inside Ralf's comment.

          Show
          sdrees Stefan Drees (Inactive) added a comment - Is there a mapping to base a transform for the MetaModel.edmx transition from v3 to v4 upon? I'ld be willing to act on the first item in the above todo lit (inside Ralf's comment.
          Hide
          ralfhandl Ralf Handl added a comment - - edited

          The transformation steps needed are:

          • Keep edmx:Edmx wrapper element, change xmlns:edmx to new edmx and make Version=4.0"
          • Translate edmx:Edmx/edmx:Runtime/edmx:ConceptualModels into edmx:DataServices
          • Keep Schema element, change xmlns to new edm, remove all other xmlns:xxx attributes
          • Keep EntityType, ComplexType, EnumType, EntityContainer, remove Association (and maybe more)
          • Keep NavigationProperty, use Relationship and ToRole to extract Type from corresponding Association/End, using Multiplicity="*" for Collection(...)

          Here are two files, one V3 produced with Visual Studio, one V4 transformed manually, to be used for testing an automatic transformation:

          And here's a first shot at the transformation: https://tools.oasis-open.org/version-control/browse/wsvn/odata/trunk/spec/examples/MetadataService/V3-to-V4-CSDL.xsl

          Show
          ralfhandl Ralf Handl added a comment - - edited The transformation steps needed are: Keep edmx:Edmx wrapper element, change xmlns:edmx to new edmx and make Version=4.0" Translate edmx:Edmx/edmx:Runtime/edmx:ConceptualModels into edmx:DataServices Keep Schema element, change xmlns to new edm, remove all other xmlns:xxx attributes Keep EntityType, ComplexType, EnumType, EntityContainer, remove Association (and maybe more) Keep NavigationProperty, use Relationship and ToRole to extract Type from corresponding Association/End, using Multiplicity="*" for Collection(...) Here are two files, one V3 produced with Visual Studio, one V4 transformed manually, to be used for testing an automatic transformation: https://tools.oasis-open.org/version-control/browse/wsvn/odata/trunk/spec/examples/MetadataService/TestV3.edmx https://tools.oasis-open.org/version-control/browse/wsvn/odata/trunk/spec/examples/MetadataService/TestV4.edmx And here's a first shot at the transformation: https://tools.oasis-open.org/version-control/browse/wsvn/odata/trunk/spec/examples/MetadataService/V3-to-V4-CSDL.xsl
          Hide
          ralfhandl Ralf Handl added a comment -

          Removed typos

          • EntityType and ComplexType inherit from Type, so no Key, Fullname and Name
          • Navigation property Schema consistently had wrong type: EntityContainer -> Schema
          • NamedEntities not directly related to Schema, only to EntityContainer
          • ParameterType was used via NavigationProperty, but is complex type -> Property
          • Include/Uri -> Include/Namespace
          • Introduced complex type KeyProperty to reflect our new Alias attribute for key properties
          • Cleaned up Nullable facet: optionality in XML-CSDL no longer reflected, instead MetadataService will show default value
          Show
          ralfhandl Ralf Handl added a comment - Removed typos EntityType and ComplexType inherit from Type, so no Key, Fullname and Name Navigation property Schema consistently had wrong type: EntityContainer -> Schema NamedEntities not directly related to Schema, only to EntityContainer ParameterType was used via NavigationProperty, but is complex type -> Property Include/Uri -> Include/Namespace Introduced complex type KeyProperty to reflect our new Alias attribute for key properties Cleaned up Nullable facet: optionality in XML-CSDL no longer reflected, instead MetadataService will show default value
          Hide
          sdrees Stefan Drees (Inactive) added a comment - - edited

          Reference to meeting #41 minute link fragment documenting the approval of application has been added.

          Show
          sdrees Stefan Drees (Inactive) added a comment - - edited Reference to meeting #41 minute link fragment documenting the approval of application has been added.

            People

            • Assignee:
              handl Ralf Handl
              Reporter:
              handl Ralf Handl
            • Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: