ibatis-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Kai Grabfelder <nos...@kaigrabfelder.de>
Subject Re: JPA Annotations + iBatis
Date Sun, 07 Jun 2009 08:18:47 GMT
Clinton added Annotation support to iBATIS 3 but it was dropped due to a problem with circular
between resultmaps. Unfortunately we found no solution for that so I guess using JPA instead
annotations doesn't help as well.



--- Original Nachricht ---
Absender: Yuri de Wit
Datum: 04.06.2009 23:35
> Would it be possible to have iBatis reuse JPA persistence annotations to
> infer resultmaps/submaps/discriminators and still allow me to customize the
> SQL behind the scenes?
> I am creating a bi-temporal data model and I am finding JPA a bit limiting
> since it assumes a certain model for inserts, updates, and deletes. In my
> case, for instance an update translates into an update + insert with added
> assertions as where criteria and JPA doesnt offer me that kind of
> flexibility. On the one hand, I am sold on class annotations to describe
> mappings from classes/fields to tables/columns and the standard api to
> persist, delete, etc, but on the other hand I would like to have total
> freedom to craft my own SQL behind the scenes.
> IBatis seems the perfect solution for me: total flexibility in the
> mappings/statements with support for polymorphic queries etc. Thats when it
> occurred to me what a great combination it would be if iBatis could reuse
> the JPA persistence annotations to infer resultmaps and allow me to provide
> the SQL to CRUD the POJOs. iBatis could even provide standard SQL queries
> that would mimic the semantic of JPA although in my case I would rewrite
> those.
> Does something like this even make sense? Maybe there is even an open source
> JPA implementation with a good separation of concerns so that the
> annotations and API implementation could be reused to plugin the iBatis back
> end.  Maybe this could even increase the adoption of iBatis?
> best regards,
> -- yuri

View raw message