Details
-
Type:
Improvement
-
Status:
Closed
-
Priority:
Major
-
Resolution: Fixed
-
Affects Version/s: 1.2, 1.3, 1.3.1
-
Fix Version/s: 1.3.2
-
Component/s: JDO queries
-
Labels:None
-
Number of attachments :
Description
During GSoC 2008 Udai Gupta will work at refactoring OQL query engine. The original project idea is:
The object query language that Castor supports today is quite limited and has to be improved in some ways. On the other hand this task is very difficult as the codebase of the query engine is a bit crapy and split over many classes in different packages. To overcome this situation we plan to approach the problem from 2 sides. One is to refactor the generation of SQL queries at the current codebase. We think that this should make it much easier to replace the OQL to SQL transformation and plugin a new object query language later on. The implementation of the new OQL from scratch is the other side to approach a solution.
For the new object query language we like to conform to EJB QL specified at persistence part of EJB 3.0 specification. The specification can be downlaoded from http://jcp.org/aboutJava/communityprocess/final/jsr220/index.html.
As it will be quite difficult to implement the whole language at once, the first task will be to define a roadmap for the implementation. The roadmap should contain a list of features as well as the BNF for each step of the implementation. Based on this roadmap we intend to define your targets for the project together with you.
The base idea for the implementation is the create a class for every element of the language. This will enable us to represent a query with a hierarchy of objects of these classes. By calling toString() at the root of the hierarchy a string representation of the query can be generated. For the opposit direction, to transfor a query string into a class hierarchy, you generate a parser using a parser generator like JavaCC or antlr. Apart of the featurs you have to implement junit tests to verify that your implementation works as expected.
To limit the scope of this project, we do not expect you to implement the full specification nor to integrate the new object query language into Castor. This will be done later on at a follow up project. We only expect you to implement the query string to object transformation and vice versa for a subset of the language.
Issue Links
- is related to
-
CASTOR-2616
Refactor query objects created during GSoC 2008 to comply with JPA 2.0 criteria API
-
- relates to
-
CASTOR-2377
Refactor old tests TC30 and TC31
-
-
CASTOR-2796
Add query objects as created at GSoC 2008 to SVN trunc
-
-
CASTOR-324
Castor's OQL implementation should be refactored to make use of ANTLR
-
-
CASTOR-2368
Creating a How To for setting the castor project in Eclipse
-
Udai created a series of howto documents about setting up Castor with eclipse and about execution of Castor's JDO test suites based on the introduction from me.