/** * @see org.kuali.rice.krad.dao.PersistenceDao#resolveProxy(java.lang.Object) */ @Override public Object resolveProxy(Object o) { Identity ident = new IdentityFactoryImpl(getPersistenceBroker(true)).buildIdentity(o); IndirectionHandlerCGLIBImpl ih = new IndirectionHandlerCGLIBImpl(getPersistenceBroker(true).getPBKey(), ident); return ih.getRealSubject(); }
public ConnectionManagerImpl(PersistenceBroker broker) { this.broker = broker; this.pbKey = broker.getPBKey(); this.jcd = MetadataManager.getInstance().connectionRepository().getDescriptor(pbKey); this.connectionFactory = setupConnectionFactory(jcd); this.platform = PlatformFactory.getPlatformFor(jcd); /* by default batch mode is not enabled and after use of a PB instance, before instance was returned to pool, batch mode was set to false again (PB implementation close method) Be carefully in modify this behaviour, changes could cause unexpected behaviour */ setBatchMode(false); // save connection manager instance ConnectionManagerManagementBean.addConnectionManager(this); }