You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@olingo.apache.org by "Christian Amend (JIRA)" <ji...@apache.org> on 2015/08/21 10:20:45 UTC
[jira] [Resolved] (OLINGO-679) URI parser does not allow counting
filtered collections
[ https://issues.apache.org/jira/browse/OLINGO-679?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Christian Amend resolved OLINGO-679.
------------------------------------
Resolution: Fixed
Assignee: Christian Amend
Fix Version/s: (Java) V4 4.0.0
Hi,
as I can`t reproduce this behaviour with the current SNAPSHOT I would say this is fixed.
If yous still ecounter this please reopen this issue.
Best Regards,
Christian
> URI parser does not allow counting filtered collections
> -------------------------------------------------------
>
> Key: OLINGO-679
> URL: https://issues.apache.org/jira/browse/OLINGO-679
> Project: Olingo
> Issue Type: Bug
> Components: odata4-server
> Affects Versions: (Java) V4 4.0.0-beta-03
> Reporter: Frederic Souchu
> Assignee: Christian Amend
> Fix For: (Java) V4 4.0.0
>
>
> According to OData specifications:
> [11.2.9 Requesting the Number of Items in a Collection|http://docs.oasis-open.org/odata/odata/v4.0/errata02/os/complete/part1-protocol/odata-v4.0-errata02-os-part1-protocol-complete.html#_Toc406398314]
> …
> Example 64: return the number of all products whose Price is less than $10.00
> http://host/service/Products/$count?$filter=Price lt 10.00
> The /$count segment can be used in combination with the $filter system query option.
> Using provider based on the ServiceHandler class, the following URL:
> {code}
> http://localhost/myservice/Stores/$count?$filter=ID eq '123465'
> {code}
> produces that error:
> {code}
> {
> "error": {
> "code": null,
> "message": "The key value 'ID' is invalid."
> }
> }
> {code}
> Initial analysis:
> The $count option (UriResourceCountImpl) pushes a context without any type (context.contextTypes = []).
> The $filter option then raises an exception when trying to introspect the type provided by the last URI segment.
>
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)