Best of this Week Summary 15 September - 21 September 2008
- It seems the SOA world is finally starting to take the Web-Oriented Architecture seriously.
- Summary of a recent whitepaper from IBM Global Services describing five high level best practices for successful deployment of an SOA. 120 IT Architects, developers, IT Specialists and project managers evaluated nearly 100 case studies, with 750 lessons learned and 650 best practices.
- SpringSource announced a maintenance policy for SpringSource Enterprise. Definitely check Rod Johnson's clarification comment in this thread on The ServerSide. Important to verify when you're using Spring in your company.
- Elaborate introduction to persistence, ORM and JPA, and a comprison of two open source persistence frameworks: iBATIS and Hibernate. Notable points: iBATIS encourages the direct use of SQL queries; it enables the object model and the data model to be independent of eachother via its data mapper (compared to a metadata mapper framework like Hibernate). Note that fully ORM tools generate SQL, where iBATIS uses SQL directly. A nice quick overview of the Hibernate architecture is described; the diagram is shown below:
Recommendations from the article:- Use iBATIS when you need full control of the SQL
- Don't use iBATIS when you are in full control of both the application (with its domain model) and the data model.
- Don't use iBATIS when the database is non-relational
- Use Hibernate to leverage end-to-end OR mapping
- A potential reason to use it could be that it is more easy to use for object-oriented programmers who are less familiar with SQL
- Use JPA when you need a standards-based persistence solution
My own recommendations:- With Hibernate it might be harder to tune the queries because they are generated by Hibernate. You can't really "just handover" the queries to the DBA. The DBA will have to monitor the database for bad queries.
- Hibernate gets quite complex when you have to map more complex associations (like a unidirectional many-to-many association with custom columns added to the link-table). I've never used iBatis so can't tell how hard it is for that framework.
- When trying to only use JPA defined elements, you'll find that JPA's possibilities are quite limited (e.g. caching is not well defined in JPA), and that you quickly will start to use (ORM-tool) implementation specific features. A good way to implement this, is to specify the full package path when using implementation specific annotations. That way you can see where you deviate from the JPA standard.
- Use iBATIS when you need full control of the SQL
No comments:
Post a Comment