[ https://issues.apache.org/jira/browse/JDO-652?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14902690#comment-14902690 ]
Tilmann Zäschke commented on JDO-652: ------------------------------------- In https://issues.apache.org/jira/browse/JDO-749, ANdy wore in response to my question about streams/lambdas in queries: ??And about yet another 'redesign' of the query API, we have waited nearly 3 years for this one from the provision of the DN TypesafeQuery API with little input from others. Bear in mind that I wouldn't be contributing much time, so if you want it then you need to provide time/ideas/implementations/tests.?? Sorry, I only really joined the discussions here a few months ago, I don't know the history, but I certainly don't want to be disruptive. I thought about streams/lambdas a bit more, and I think one key issue is that the API will look very different from JDOQL or the proposed typesafe API, it simply will have to look like the Java 8 stream API ({{filter()}}, {{reduce()}}, {{sort()}}, {{forEach()}}, ...). Also, it will require considerable effort to even verify feasibility, I guess at least another 6 months at least. The result may be that it actually doesn't really work or makes sense. I don't know what the JDO 3.2 timeline is, but I suspect it may be best to follow through with the current proposal. I suppose the disadvantage of duplicating the query at a later point with a stream API is smaller than waiting for an API that may not even work. I guess it boils down to the argument that having a 'very good' solution now is preferable to potentially 'perfect' solution that may never come. > Provision of a typesafe refactor-friendly query capability for JDOQL > -------------------------------------------------------------------- > > Key: JDO-652 > URL: https://issues.apache.org/jira/browse/JDO-652 > Project: JDO > Issue Type: New Feature > Components: api, specification, tck > Reporter: Andy Jefferson > Fix For: JDO 3.2 > > Attachments: typesafe.patch, typesafe_manifest.patch > > > There are various querying capabilities of this type around. JPA2 has its > Criteria query API. Third party solutions like QueryDSL also exist, in its > case providing a JDOQL implementation (as well as JPQL, and HQL). We should > seriously consider introducing something along these lines in the JDO2.4 > timeframe. > There is a comparison of JPA Criteria with QueryDSL over at > http://source.mysema.com/forum/mvnforum/viewthread_thread,49 -- This message was sent by Atlassian JIRA (v6.3.4#6332)