You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@olingo.apache.org by "Dmitry Volodin (JIRA)" <ji...@apache.org> on 2015/08/20 18:29:46 UTC
[jira] [Commented] (OLINGO-762) Cannot find type with name:
Edm.DateTime
[ https://issues.apache.org/jira/browse/OLINGO-762?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14705219#comment-14705219 ]
Dmitry Volodin commented on OLINGO-762:
---------------------------------------
Looks like this issue happens during source code restructure from beta-02 to beta-03, as for 4.0.0-beta02 this code was working fine
> Cannot find type with name: Edm.DateTime
> ----------------------------------------
>
> Key: OLINGO-762
> URL: https://issues.apache.org/jira/browse/OLINGO-762
> Project: Olingo
> Issue Type: Bug
> Components: odata4-client
> Affects Versions: (Java) V4 4.0.0-beta-03
> Environment: Following code fails when getting entity based on XML data with DateTime property
> URI customersUri = client.newURIBuilder().appendEntitySetSegment("Document_АвансовыйОтчет").build();
> ODataEntitySetIteratorRequest<ClientEntitySet, ClientEntity> req = client.getRetrieveRequestFactory().getEntitySetIteratorRequest(customersUri);
> req.setContentType("application/xml");
> req.setAccept("application/xml");
> ODataRetrieveResponse<ClientEntitySetIterator<ClientEntitySet, ClientEntity>> rsp = req.execute();
> ClientEntitySetIterator<ClientEntitySet, ClientEntity> iterator = rsp.getBody();
>
> while (iterator.hasNext()) {
> ClientEntity customer = iterator.next();
> List<ClientProperty> properties = customer.getProperties();
> for (ClientProperty property : properties) {
> String name = property.getName();
> ClientValue value = property.getValue();
> String valueType = value.getTypeName();
> }
> }
> Reporter: Dmitry Volodin
> Priority: Critical
>
> Exception in thread "main" org.apache.olingo.commons.api.edm.EdmException: Cannot find type with name: Edm.DateTime
> at org.apache.olingo.commons.core.edm.EdmPropertyImpl.getType(EdmPropertyImpl.java:51)
> at org.apache.olingo.client.core.serialization.ODataBinderImpl.getODataEntity(ODataBinderImpl.java:659)
> at org.apache.olingo.client.api.domain.ClientEntitySetIterator.next(ClientEntitySetIterator.java:141)
> at ru.oracle.com.demo.odins.odata.ODataClientTest.listEntityData(ODataClientTest.java:90)
> at ru.oracle.com.demo.odins.odata.ODataClientTest.main(ODataClientTest.java:104)
> Process exited.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)