The main advantage of this proxy is that it allows DAOs to work with a plain JDO PersistenceManager reference in JDO 2.1 style (see {@link javax.jdo.PersistenceManagerFactory#getPersistenceManagerProxy()}), while still participating in Spring's resource and transaction management.
The behavior of this proxy matches the behavior that the JDO 2.1 spec defines for a PersistenceManager proxy. Hence, DAOs could seamlessly switch between {@link StandardPersistenceManagerProxyBean} and this Spring-style proxy,receiving the reference through Dependency Injection. This will work without any Spring API dependencies in the DAO code!
Note: In contrast to {@link StandardPersistenceManagerProxyBean}, this proxy works with JDO 2.0 and higher. It does not require JDO 2.1. @author Juergen Hoeller @since 3.0 @see StandardPersistenceManagerProxyBean @see javax.jdo.PersistenceManagerFactory#getPersistenceManagerProxy() @see org.springframework.orm.jdo.PersistenceManagerFactoryUtils#getPersistenceManager @see org.springframework.orm.jdo.PersistenceManagerFactoryUtils#releasePersistenceManager
|
|