Uploaded image for project: 'OASIS Open Data Protocol (OData) TC'
  1. OASIS Open Data Protocol (OData) TC
  2. ODATA-1072

Annotation to describe supported aggregation methods

    Details

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

      Applied

    • Proposal:
      Hide

      This feature should be offered for entity containers and entity sets instead of structure properties, in the same way as we decided for other terms of the Aggregation vocabulary, cf. ODATA-1382--

      Show
      This feature should be offered for entity containers and entity sets instead of structure properties, in the same way as we decided for other terms of the Aggregation vocabulary, cf. ODATA-1382 --
    • Resolution:
      Show
      https://github.com/oasis-tcs/odata-vocabularies/pull/95

      Description

      A service may support only a subset of all standard and custom aggregation methods advertised in annotation ApplySupported/CustomAggregationMethods for certain aggregatable properties. If deviations from the full set could be annotated at property level, clients would be able to recognize them and avoid requests that will be rejected by the server. In particular, this would also support the special case of an aggregatable property that does not support any aggregation method, but there is a CustomAggregate annotation with the name of the property as qualifier. Then, the property could still be used in the aggregate transformation without "with", and could also be annotated with further terms.

        Attachments

          Activity

          Hide
          handl Ralf Handl added a comment - - edited

          Gerald to extend the proposal for the next meeting:

          • make this a structured term that also has a property for the recommended (single) aggregation method
          Show
          handl Ralf Handl added a comment - - edited Gerald to extend the proposal for the next meeting: make this a structured term that also has a property for the recommended (single) aggregation method
          Hide
          gerald.krause1 Gerald Krause added a comment -

          1.

          The current proposal to add a structured term with a collection-valued property for SupportedAggregationMethods includes the description that omitting this property in an annotation means that all aggregation methods can be applied, which contradicts with CSDL spec, section 14.4.12, fourth para.

          To convey the expected meaning that the absence of SupportedAggregationMethods implies support for all methods, separate terms could be introduced instead:

          <Term Name="SupportedAggregationMethods" Type="Collection(Edm.String)" AppliesTo=”Property”>
          <Annotation Term="Core.Description">
          <String>Standard and custom aggregation methods than can be applied to the property. If omitted, all aggregation methods can be applied</String>
          </Annotation>
          </Term>

           

          <Term Name="RecommendedAggregationMethod" Type="Edm.String" AppliesTo=”Property”>
          <Annotation Term="Core.Description">
          <String>Recommended method for aggregating values of the property</String>
          </Annotation>
          </Term>

          2.

          In addition, if a service implementation supports only a subset of the defined aggregation methods, applying term SupportedAggregationMethods to entity types and containers may become handy to avoid repeating the same restriction for every aggregatable property.

          Show
          gerald.krause1 Gerald Krause added a comment - 1. The current proposal to add a structured term with a collection-valued property for SupportedAggregationMethods includes the description that omitting this property in an annotation means that all aggregation methods can be applied, which contradicts with CSDL spec, section 14.4.12, fourth para. To convey the expected meaning that the absence of SupportedAggregationMethods implies support for all methods, separate terms could be introduced instead: <Term Name="SupportedAggregationMethods" Type="Collection(Edm.String)" AppliesTo=”Property”> <Annotation Term="Core.Description"> <String>Standard and custom aggregation methods than can be applied to the property. If omitted, all aggregation methods can be applied</String> </Annotation> </Term>   <Term Name="RecommendedAggregationMethod" Type="Edm.String" AppliesTo=”Property”> <Annotation Term="Core.Description"> <String>Recommended method for aggregating values of the property</String> </Annotation> </Term> 2. In addition, if a service implementation supports only a subset of the defined aggregation methods, applying term SupportedAggregationMethods to entity types and containers may become handy to avoid repeating the same restriction for every aggregatable property.
          Hide
          handl Ralf Handl added a comment -

          Resolved 2018-12-20

          Show
          handl Ralf Handl added a comment - Resolved 2018-12-20
          Hide
          gerald.krause1 Gerald Krause added a comment -

          This feature should be offered for entity containers and entity sets instead of structure properties, in the same way as we decided for other terms of the Aggregation vocabulary, cf. ODATA-1382--

          Here is a pull request for such a change: https://github.com/oasis-tcs/odata-vocabularies/pull/95

          Show
          gerald.krause1 Gerald Krause added a comment - This feature should be offered for entity containers and entity sets instead of structure properties, in the same way as we decided for other terms of the Aggregation vocabulary, cf. ODATA-1382 -- Here is a pull request for such a change: https://github.com/oasis-tcs/odata-vocabularies/pull/95
          Hide
          gerald.krause1 Gerald Krause added a comment -

          TC call 2020-11-19

          Show
          gerald.krause1 Gerald Krause added a comment - TC call 2020-11-19

            People

            • Assignee:
              Unassigned
              Reporter:
              gerald.krause1 Gerald Krause
            • Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: