I've been playing around with Perisistence frameworks lately, after been inspired by a Hibernate presento at our local JUG. After messing around with Hibernate config issues for ages, I decided to scout around for a lighter weight alternative for my little app and had my first experience with iBatis SQL Maps. All I can say is... Wow!
I've played around with Hibernate before, and it is power unlimited. But rather than getting lost in the Hibernate magic for a little lightweight app I'm working on, I thought I'd shoot for something a little less complicated. Enter SQL Maps...
What I love about this product is that:
The general gist is that you develop up a little bit of XML sauce to handle the actual query marshalling, ala:
Then you call the library with something like...
List allMsgs = sqlMap.queryForList("getAllMessageDTO",null);
and get back a list of populated objects. Admittedly not quiet as elegant as Hibernate, as the list isn't live, but cool none the less.
You can, of course, put #property# type tags in the SQL which will map to an introspected Javabean property of the object you pass in, so it's very simple to do all standard db select/insert/update/delete goodness.
The doco is very solid, with tutorial/reference/developer PDFs all in good form. As a lightweight persistence library, where Hibernate would be overkill, but where JDBC is just clunky, this library has really found a sweet spot. I'm sold. Very good stuff.