Examples of predeploy()


Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

                ++ EntityManagerFactoryProvider.PUIUsageCount;
            }
          
   
            // A call to predeploy will partially build the session we will use
            final ClassTransformer transformer = emSetupImpl.predeploy(persistenceUnitInfo, mergedProperties);
   
            registerTransformer(transformer, persistenceUnitInfo);
            return true;
        }
        return false;
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

            // 253701: cache a reference to (this) PersistenceProvider's initializer for later use during undeploy()
            emSetupImpl.setPersistenceInitializationHelper(this.initializationHelper);
           
            // call predeploy
            // this will just increment the factory count since we should already be deployed
            emSetupImpl.predeploy(emSetupImpl.getPersistenceUnitInfo(), nonNullProperties);
        }
           
        EntityManagerFactoryImpl factory = null;
        try {
            factory = new EntityManagerFactoryImpl(emSetupImpl, nonNullProperties);
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

            if (emSetupImpl == null){
                emSetupImpl = new EntityManagerSetupImpl();
                isNew = true;
                emSetupImpl.setIsInContainerMode(true);       
                // if predeploy fails then emSetupImpl shouldn't be added to FactoryProvider
                transformer = emSetupImpl.predeploy(info, nonNullProperties);
                EntityManagerFactoryProvider.addEntityManagerSetupImpl(esiName, emSetupImpl);
            }
        }
           
        if(!isNew) {
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

            }
        }
           
        if(!isNew) {
            // emSetupImpl has been already predeployed, predeploy will just increment factoryCount.
            transformer = emSetupImpl.predeploy(info, nonNullProperties);
        }
        if (transformer != null){
            info.addTransformer(transformer);
        }
        // When EntityManagerFactory is created, the session is only partially created
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

        persistenceUnitInfo.setNewTempClassLoader(tempLoader);

        EntityManagerSetupImpl emSetupImpl = new EntityManagerSetupImpl(persistenceUnitUniqueName, sessionName);

        // A call to predeploy will partially build the session we will use
        final ClassTransformer transformer = emSetupImpl.predeploy(persistenceUnitInfo, mergedProperties);

        // After preDeploy it's impossible to weave again - so may substitute the temporary classloader with the real one.
        // The temporary classloader could be garbage collected even if the puInfo is cached for the future use by other emSetupImpls.
        persistenceUnitInfo.setNewTempClassLoader(persistenceUnitInfo.getClassLoader());
       
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

                // persistence unit cannot be used standalone (only as a composite member).
                // still the factory will be created but attempt to createEntityManager would cause an exception.
                emSetupImpl = new EntityManagerSetupImpl(name, name);
                // predeploy assigns puInfo and does not do anything else.
                // the session is not created, no need to add emSetupImpl to the global map.
                emSetupImpl.predeploy(puInfo, nonNullProperties);
                isNew = true;
            } else {
                if(initializer.isPersistenceUnitUniquelyDefinedByName()) {
                    uniqueName = name;
                } else {
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

                        } else {
                            // create and predeploy a new emSetupImpl
                            emSetupImpl = initializer.callPredeploy(puInfo, nonNullProperties, uniqueName, sessionName);
                        }
                        // emSetupImpl has been already predeployed, predeploy will just increment factoryCount.
                        emSetupImpl.predeploy(emSetupImpl.getPersistenceUnitInfo(), nonNullProperties);
                        EntityManagerFactoryProvider.addEntityManagerSetupImpl(sessionName, emSetupImpl);
                        isNew = true;
                    }
                }
            }
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

                if(emSetupImpl.isUndeployed()) {
                    undeployed = true;
                }
               
                // emSetupImpl has been already predeployed, predeploy will just increment factoryCount.
                emSetupImpl.predeploy(emSetupImpl.getPersistenceUnitInfo(), nonNullProperties);
            }
            if(undeployed) {
                // after the emSetupImpl has been obtained from emSetupImpls
                // it has been undeployed by factory.close() in another thread - start all over again.
                return createEntityManagerFactory(emName, properties);
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

            // persistence unit cannot be used standalone (only as a composite member).
            // still the factory will be created but attempt to createEntityManager would cause an exception.
            emSetupImpl = new EntityManagerSetupImpl(info.getPersistenceUnitName(), info.getPersistenceUnitName());
            // predeploy assigns puInfo and does not do anything else.
            // the session is not created, no need to add emSetupImpl to the global map.
            emSetupImpl.predeploy(info, nonNullProperties);
        } else {
            boolean isNew = false;
            ClassTransformer transformer = null;
            String uniqueName = PersistenceUnitProcessor.buildPersistenceUnitName(info.getPersistenceUnitRootUrl(), info.getPersistenceUnitName());
            String sessionName = EntityManagerSetupImpl.getOrBuildSessionName(nonNullProperties, info, uniqueName);
View Full Code Here

Examples of org.eclipse.persistence.internal.jpa.EntityManagerSetupImpl.predeploy()

                if (emSetupImpl == null){
                    emSetupImpl = new EntityManagerSetupImpl(uniqueName, sessionName);
                    isNew = true;
                    emSetupImpl.setIsInContainerMode(true);       
                    // if predeploy fails then emSetupImpl shouldn't be added to FactoryProvider
                    transformer = emSetupImpl.predeploy(info, nonNullProperties);
                    EntityManagerFactoryProvider.addEntityManagerSetupImpl(sessionName, emSetupImpl);
                }
            }
               
            if(!isNew) {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.