|EMT Texo: Latest Build and Backward Compatibility [message #879578]
||Thu, 31 May 2012 13:12
| Martin Taal
Registered: July 2009
I published a new build of Texo with many changes in the way the ORM generator generates db schema names. The goal is to
make the default behavior as safe as possible preventing name collisions.
***The big drawback/problem is that this latest build of Texo is probably not backward compatible with previously
I don't like this but as Texo is still incubation and as the changes are really needed to get to a much more stable and
robust mapping I felt that it was necessary for now. I will ofcourse prevent this as much as possible in the future.
To see any differences with the previous mapping, it is best to generate an orm.xml file using the previous version of
Texo and generate a new orm.xml with the latest version, and then compare the differences.
Summary of the changes:
>>> New/changed ORM Mapping Options <<<
Defaults of several options on the EPackageORMAnnotation have changed, new options have been added:
- addOrderColumnToListMappings: false
- enforceUniqueNames: true
- renameSQLReservedNames: true
- generateFullDbSchemaNames: true
With generateFullDbSchemaNames to false, Texo generated too many annotations, this has now been changed, so if
generateFullDbSchemaNames is false then only the minimal required annotations are generated, leaving the rest to the ORM
layer. However, if generateFullDbSchemaNames is true then the full set of annotations is generated to fully control the
db schema mapping.
The options can now also be set in the project properties:
- add the Texo nature to the project, right-click on the project, in the configure submenu, select 'add/remove Texo Nature'
- then go to the project properties, to the Texo section
- on the ORM Mapping tab you can set some ORM Mapping defaults
- these defaults can be overridden in the EPackage ORM annotation
See this wiki page:
>>> DB Schema Name Truncation <<<
The name truncation has changed also. Oracle has a maximum name length of 30 for which this is especially relevant. The
truncation will first remove all vowels starting from the back of the name (previously it started from the front), this
gives better name preservation for prefixes which are part of the name.
>>> Object Copier and Object Comparator <<<
New ObjectCopier and ObjectComparator classes/logic have been added to Texo.
>>> Model-driven/level testing: large increase in test coverage <<<
A more hidden development is that I have made several test cases on so-called model-level. These testcases are generic
and can be used for any model. Currently Texo has 52 test models with 3-4 generic testcases: JPA, JSON serialization,
The result is that the number of testcases has increased from about 130 to 375+. Giving much better testcoverage.
The upcoming weeks I will blog about these changes in some more detail.
With Regards, Martin Taal
Office: Hardwareweg 4, 3821 BV Amersfoort
Postal: Nassaulaan 7, 3941 EC Doorn
Cell: +31 (0)6 288 48 943
Tel: +31 (0)84 420 2397
Fax: +31 (0)84 225 9307
Mail: mtaal@xxxxxxxx - mtaal@xxxxxxxx
Web: www.springsite.com - www.elver.org
Powered by FUDForum
. Page generated in 0.02227 seconds