OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.

 


Help: OASIS Mailing Lists Help | MarkMail Help

odata message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]


Subject: [OASIS Issue Tracker] (ODATA-1043) Clean up context URL syntax


    [ https://issues.oasis-open.org/browse/ODATA-1043?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=65493#comment-65493 ] 

Evan Ireland commented on ODATA-1043:
-------------------------------------

Our SAP-internal OData core framework (used in mobility platform) sometimes relies on context URL to identify the entity type in responses (via the entity set name in the context URL, we can then obtain the entity type since we have the parsed metadata document available).

One use case is: the client application provides a query URL (rather than constructing it via a URL builder), and we want to instantiate entities of the correct type (e.g. proxy class instances) when parsing a response.

Our preference is for minimal metadata in responses, relying on service metadata document that we preload before sending any requests. But in cases where the minimal metadata might omit "@odata.type", we want to avoid the client having to parse its own query URL to determine what it is expecting to receive.

In any case, context URLs that would simply the entity type would be helpful. Since currently, we almost need a full-blown URL parser in the client to be able to parse context URLs.



> Clean up context URL syntax
> ---------------------------
>
>                 Key: ODATA-1043
>                 URL: https://issues.oasis-open.org/browse/ODATA-1043
>             Project: OASIS Open Data Protocol (OData) TC
>          Issue Type: Bug
>          Components: Protocol
>    Affects Versions: V4.01_CSD01
>         Environment: Proposed
>            Reporter: Ralf Handl
>             Fix For: V4.01_CSD02
>
>
> 1) Chapter 10 states: The context URL describes the content of the payload. It consists of the canonical metadata document URL and a fragment *identifying the relevant portion of the metadata document.*
> This is somewhat violated by context urls using the template variable {entity} whose value is the canonical URL of an entity, including its key values - the key values aren't needed to identify the relevant portion of the metadata document, for this purpose the type is sufficient.
> 2) Chapter 10 states: Request payloads generally do not require context URLs as the type of the payload can generally be determined from the request URL.
> Can we have the same for response payloads? Most responses for requests to entity sets or singletons using canonical URLs would not need a context URL, same for navigation paths with a navigation property binding. Instances with a type derived from the declared type carry the @odata.type annotation, so even those don't need a context URL. Same for responses to actions/functions with an EntitySetPath, or action/function imports with a an EntitySet.



--
This message was sent by Atlassian JIRA
(v6.2.2#6258)


[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [List Home]