This article, written by Dr. Yun Ding and Karsten Klein, describes a unique and interesting approach to modularization and transaction management with Spring and Hibernate. Similar to the OSGi JPA Service Specification, it allows each persistent module of an enterprise application to have its own individually configured, module-specific SessionFactory.Consequently, both entity classes and the associated SessionFactory configuration of a module are isolated from other modules. On one hand, modularization enforces isolation between modules, but on the other, it increases the need for coordination between them from within the scope of a transaction.

Read more:

Modularizing the Hibernate SessionFactory with the Spring framework


Related Books & Resources

OSGi in Action: Creating Modular Applications in Java
Modular Java: Creating Flexible Applications with Osgi and Spring 
Hibernate Made Easy: Simplified Data Persistence with Hibernate and JPA 
Java Persistence with Hibernate
Spring Enterprise Recipes: A Problem-Solution Approach