[jira] [Commented] (OLINGO-976) Problem with JTA transactions
[ https://issues.apache.org/jira/browse/OLINGO-976?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15359049#comment-15359049 ] Alex Key commented on OLINGO-976: - Hi Michael, I just made a quick check - that exception went away, but we still have a problem here with container managed transactions. Right now I get javax.persistence.TransactionRequiredException because UserTransaction is not started when the request is routed through olingo. I don't have any ideas at the moment how to fix that, but perhaps we need to pass UserTransaction to olingo too to do all that begin/commit/rollback work (not sure if that is doable). I need to give it some thought. Best regards, Alex > Problem with JTA transactions > - > > Key: OLINGO-976 > URL: https://issues.apache.org/jira/browse/OLINGO-976 > Project: Olingo > Issue Type: Bug > Components: odata2-jpa >Affects Versions: V2 2.0.7 > Environment: neo-javaee6-wp-sdk (SAP HANA cloud) >Reporter: Alex Key >Assignee: Michael Bolz > Fix For: V2 2.0.7 > > > There are still problems with JTA transaction after fixing OLINGO-882. > At the moment IllegalStateException is thrown by > ODataJPATransactionLocalDefault constructor, which has em.getTransaction() > call. > Here's stacktrace: > {code} > java.lang.IllegalStateException: A JTA EntityManager can not use the > EntityTransaction API. See JPA 1.0 section 5.5 > at > org.apache.openejb.persistence.JtaEntityManager.getTransaction(JtaEntityManager.java:349) > at > org.apache.olingo.odata2.jpa.processor.core.ODataJPATransactionLocalDefault.(ODataJPATransactionLocalDefault.java:31) > at > org.apache.olingo.odata2.jpa.processor.core.ODataJPAContextImpl.getODataJPATransaction(ODataJPAContextImpl.java:178) > at > org.apache.olingo.odata2.jpa.processor.core.access.data.JPAProcessorImpl.setTransaction(JPAProcessorImpl.java:451) > at > org.apache.olingo.odata2.jpa.processor.core.access.data.JPAProcessorImpl.processCreate(JPAProcessorImpl.java:335) > at > org.apache.olingo.odata2.jpa.processor.core.access.data.JPAProcessorImpl.process(JPAProcessorImpl.java:223) > at > org.apache.olingo.odata2.jpa.processor.core.ODataJPAProcessorDefault.createEntity(ODataJPAProcessorDefault.java:122) > at org.apache.olingo.odata2.core.Dispatcher.dispatch(Dispatcher.java:79) > at > org.apache.olingo.odata2.core.ODataRequestHandler.handle(ODataRequestHandler.java:130) > at > org.apache.olingo.odata2.core.rest.ODataSubLocator.handle(ODataSubLocator.java:164) > at > org.apache.olingo.odata2.core.rest.ODataSubLocator.handlePost(ODataSubLocator.java:86) > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OLINGO-964) Cast type (typeFilterOnCollection) not taken into account while expanding a collection
[ https://issues.apache.org/jira/browse/OLINGO-964?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15359483#comment-15359483 ] Jacek Miłaczewski commented on OLINGO-964: -- To be honest, I hoped that you say something more, maybe disagree with me ;) I am not sure if it is right solution from OASIS standard point of view. For example, what about situation when I want to expand more navigation properties on Collection and these properties are from two or more different subtypes? To extend my description: User want to expand collection of entities (e.g. 'Products') with casting type of this collection to some subtype (''FeaturedProduct) and use property from this subtype as navigation property to be expanded ('Advertisement') but also want to cast this collection to another subtype ("DifferentProduct") and expand property from this different subtype ("AnotherProperty"). How to do that? > Cast type (typeFilterOnCollection) not taken into account while expanding a > collection > -- > > Key: OLINGO-964 > URL: https://issues.apache.org/jira/browse/OLINGO-964 > Project: Olingo > Issue Type: Bug > Components: odata4-server >Affects Versions: (Java) V4 4.2.0, (Java) V4 4.3.0 >Reporter: Jacek Miłaczewski >Priority: Critical > Attachments: > 0001-fix-proposal-for-cast-type-not-taken-into-account-wh.patch > > > When user want to expand collection of entities (e.g. 'Products') with > casting type of this collection to some subtype (''FeaturedProduct) and use > property from this subtype as navigation property to be expanded > ('Advertisement'), error occurs because of not taking into account this > subtype in ExpandParser.java code but use only superType instead. > Example url: > http://.../OData.svc/Categories(1)?$expand=Products/ODataDemo.FeaturedProduct($expand=Advertisement) > I attach a patch with proposal fix to illustrate what is going on and how it > should work in my opinion. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OLINGO-964) Cast type (typeFilterOnCollection) not taken into account while expanding a collection
[ https://issues.apache.org/jira/browse/OLINGO-964?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15359670#comment-15359670 ] Ramesh Reddy commented on OLINGO-964: - [~jabomi] ha, are you trying to test our OData spec knowledge? ;) The relevant section I could find is [1] example 34. That also clarifies your concern about different sub-types, by filtering the results to just that type. If that is not what you are asking then may be we need to discuss further. [1] http://docs.oasis-open.org/odata/odata/v4.0/errata02/os/complete/part2-url-conventions/odata-v4.0-errata02-os-part2-url-conventions-complete.html#_Toc406398088 > Cast type (typeFilterOnCollection) not taken into account while expanding a > collection > -- > > Key: OLINGO-964 > URL: https://issues.apache.org/jira/browse/OLINGO-964 > Project: Olingo > Issue Type: Bug > Components: odata4-server >Affects Versions: (Java) V4 4.2.0, (Java) V4 4.3.0 >Reporter: Jacek Miłaczewski >Priority: Critical > Attachments: > 0001-fix-proposal-for-cast-type-not-taken-into-account-wh.patch > > > When user want to expand collection of entities (e.g. 'Products') with > casting type of this collection to some subtype (''FeaturedProduct) and use > property from this subtype as navigation property to be expanded > ('Advertisement'), error occurs because of not taking into account this > subtype in ExpandParser.java code but use only superType instead. > Example url: > http://.../OData.svc/Categories(1)?$expand=Products/ODataDemo.FeaturedProduct($expand=Advertisement) > I attach a patch with proposal fix to illustrate what is going on and how it > should work in my opinion. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (OLINGO-570) Implement OData Json Metadocument Serializer/Parser
[ https://issues.apache.org/jira/browse/OLINGO-570?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15359677#comment-15359677 ] Ramesh Reddy commented on OLINGO-570: - [~RalfHandl] Any restrictions in terms of licensing to copy XSLT file to Olingo repo? > Implement OData Json Metadocument Serializer/Parser > --- > > Key: OLINGO-570 > URL: https://issues.apache.org/jira/browse/OLINGO-570 > Project: Olingo > Issue Type: Improvement > Components: odata4-client, odata4-server >Affects Versions: (Java) V4 4.0.0-beta-02 >Reporter: Christian Amend >Assignee: Ramesh Reddy > Labels: gsoc2015, java, mentor, xml > Attachments: jsonMeta1.diff, jsonMeta2.diff, jsonMeta3.diff, > jsonMeta4.diff, jsonMetaDeserializer1.diff, jsonMetaDeserializer2.diff, > jsonMetaDeserializer3.diff, jsonMetaDeserializer4.diff > > > The Olingo project is currently working on implementing the V4 OData > specification published by oasis. The current version of the specification > only specifies a metadata document in xml format. This can be problematic on > android devices where no native xml parser is available. In a newer version > of this specification a new metadata format will be specified in Json. > The goal of this issue would be to implement a serializer which can create a > payload based on the new specification. Afterwards the Olingo client library > must be able to consume the Json metadata document by implementing a parser. > This issue could be implemented by a Student who takes part in the GSoC. The > metadata document is already available as an xml format which could give a > student a very good entry point to learn more about OData and the Olingo > library. Learning opportunities would be about Json payload creation as well > as parsing of Json payloads. This would also include understanding the latest > OData V4 specification. If you are interested comment this issue or write a > mail to dev@olingo.apache.org . > Sources: > Olingo Website: http://olingo.apache.org/ > OData.org: http://www.odata.org/ -- This message was sent by Atlassian JIRA (v6.3.4#6332)