Hi,
I try to deploy simple (enterprise) application to test how
work
deployment processing in the last build M6 (EasyBeans).
I created EAR file (ProjecT-EAR), that contains one JAR
file with two
entity classes and one persistence.xml file.
For persistence framework I choice TopLink.
In the persistence.xml file, I define two persistence-units
for every my
entity classes.
I put TopLink implementation in Tomcate's lib folder too.
When I deploy my EAR file, I see following exception:
------------------------------------------------------------
------------------------------------------------------------
---------------------------------
07-7-18 12:01:10 (I) AbsWebContainerDeployer.deployEAR :
Deploying
EARDeployableImpl[archive=....apache-tomcat-6.0.13-EBtemp
EasyBeans-Deployer-gdimitrovEARProjecT-EAR.
ear]
07-7-18 12:01:11 (I)
JPersistenceUnitInfoHelper.loadDefaultValues :
Default persistence provider set to value
org.hibernate.ejb.HibernatePersistence.
07-7-18 12:01:11 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
No default configuration for the persistence provider
oracle.toplink.essentials.PersistenceProvider
07-7-18 12:01:11 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
No default configuration for the persistence provider
oracle.toplink.essentials.PersistenceProvider
07-7-18 12:01:11 (S) DirectoryDeployerMonitor.init : Cannot
scan for new
archives
org.objectweb.easybeans.server.EmbeddedException:
RuntimeException when
deploying the deployable
'EARDeployableImpl[archive=....apache-tomcat-6.0.13-EBeasy
beans-deploy
ProjecT-EAR.ear]'
at
org.objectweb.easybeans.server.DirectoryDeployerMonitor.dete
ctNewArchives(DirectoryDeployerMonitor.java:257)
at
org.objectweb.easybeans.server.DirectoryDeployerMonitor.init
(DirectoryDeployerMonitor.java:136)
at
org.objectweb.easybeans.server.Embedded.start(Embedded.java:
296)
at
org.objectweb.easybeans.server.war.EasyBeansContextListener.
contextInitialized(EasyBeansContextListener.java:168)
at
org.apache.catalina.core.StandardContext.listenerStart(Stand
ardContext.java:3827)
at
org.apache.catalina.core.StandardContext.start(StandardConte
xt.java:4334)
at
org.apache.catalina.core.ContainerBase.addChildInternal(Cont
ainerBase.java:791)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBas
e.java:771)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.
java:525)
at
org.apache.catalina.startup.HostConfig.deployDescriptor(Host
Config.java:626)
at
org.apache.catalina.startup.HostConfig.deployDescriptors(Hos
tConfig.java:553)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig
.java:488)
at
org.apache.catalina.startup.HostConfig.start(HostConfig.java
:1138)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostCo
nfig.java:311)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent
(LifecycleSupport.java:117)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.j
ava:1053)
at
org.apache.catalina.core.StandardHost.start(StandardHost.jav
a:719)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.j
ava:1045)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine
.java:443)
at
org.apache.catalina.core.StandardService.start(StandardServi
ce.java:516)
at
org.apache.catalina.core.StandardServer.start(StandardServer
.java:710)
at
org.apache.catalina.startup.Catalina.start(Catalina.java:566
)
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:2
88)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:41
3)
Caused by: java.lang.IllegalStateException: Failure when
analyzing the
persistence.xml file
at
org.objectweb.easybeans.deployer.AbsWebContainerDeployer.dep
loyEAR(AbsWebContainerDeployer.java:158)
at
org.objectweb.easybeans.deployer.TomcatDeployer.deploy(Tomca
tDeployer.java:195)
at
org.objectweb.easybeans.server.DirectoryDeployerMonitor.dete
ctNewArchives(DirectoryDeployerMonitor.java:249)
... 27 more
Caused by:
org.objectweb.easybeans.persistence.xml.PersistenceXmlFileAn
alyzerException:
Cannot load the persistence provider class '
oracle.toplink.essentials.PersistenceProvider
'.
at
org.objectweb.easybeans.persistence.xml.PersistenceXmlFileAn
alyzer.analyzePersistenceXmlFile(PersistenceXmlFileAnalyzer.
java:119)
at
org.objectweb.easybeans.deployer.AbsWebContainerDeployer.dep
loyEAR(AbsWebContainerDeployer.java:155)
this is my persistence.xml file :
------------------------------------------------------------
--------------------------------------------------
<persistence-unit name="ProjecTDB_Oracle_PU"
transaction-type="JTA">
<provider>oracle.toplink.essentials.PersistenceProvi
der</provider>
<jta-data-source>ProjecTDBOracleJndi</jta-data-so
urce>
<class>bg......entities.ProjecT.RBEntity</class&g
t;
<exclude-unlisted-classes>true</exclude-unlisted-
classes>
<properties>
<property name="toplink.cache.type.default"
value="NONE" />
</properties>
</persistence-unit>
<persistence-unit name="ProjecTDB_MySQL_PU"
transaction-type="JTA">
<provider>oracle.toplink.essentials.PersistenceProvi
der</provider>
<jta-data-source>ProjecTDBMySQLJndi</jta-data-sou
rce>
<class>
bg......entities.ProjectT2.TUEntity
</class>
<exclude-unlisted-classes>true</exclude-unlisted-
classes>
<properties>
<property name="toplink.cache.type.default"
value="NONE" />
</properties>
</persistence-unit>
After that I decide to use default persistence
implementation –
Hibernate .
In the same EAR I comment provider tag in persistence.xml
file and I
deploy again EAR file.
Now I see different exception:
------------------------------------------------------------
------------------------------------------------------------
--------------------------------
07-7-18 14:23:29 (I) AbsWebContainerDeployer.deployEAR :
Deploying
EARDeployableImpl[archive=....apache-tomcat-6.0.13-EBtemp
EasyBeans-Deployer-gdimitrovEARProjecT-EA
ear]
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.loadDefaultValues :
Default persistence provider set to value
org.hibernate.ejb.HibernatePersistence.
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
No persistence provider was set, set to value
org.hibernate.ejb.HibernatePersistence.
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
Found a default configuration for the persistence provider
org.hibernate.ejb.HibernatePersistence
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
Setting the property
hibernate.transaction.manager_lookup_class with
value org.hibernate.transaction.JOTM
ansactionManagerLookup
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
Setting the property hibernate.cache.provider_class with
value
org.hibernate.cache.HashtableCacheProvider
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
No persistence provider was set, set to value
org.hibernate.ejb.HibernatePersistence.
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
Found a default configuration for the persistence provider
org.hibernate.ejb.HibernatePersistence
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
Setting the property
hibernate.transaction.manager_lookup_class with
value org.hibernate.transaction.JOTM
ansactionManagerLookup
07-7-18 14:23:29 (I)
JPersistenceUnitInfoHelper.getPersistenceUnitInfo :
Setting the property hibernate.cache.provider_class with
value
org.hibernate.cache.HashtableCacheProvider
07-7-18 14:23:30 (I) Version.<clinit> : Hibernate
Annotations 3.3.0.GA
07-7-18 14:23:30 (I) Environment.<clinit> : Hibernate
3.2.2
07-7-18 14:23:30 (I) Environment.<clinit> :
hibernate.properties not
found
07-7-18 14:23:30 (I) Environment.buildBytecodeProvider :
Bytecode
provider name : cglib
07-7-18 14:23:30 (I) Environment.<clinit> : using JDK
1.4
java.sql.Timestamp handling
07-7-18 14:23:30 (I) Version.<clinit> : Hibernate
EntityManager 3.3.1.GA
07-7-18 14:23:30 (I) Ejb3Configuration.configure :
Processing
PersistenceUnitInfo [
name: ProjecTDB_Oracle_PU
...]
07-7-18 14:23:30 (I) Ejb3Configuration.scanForClasses :
found EJB3
Entity bean: bg......entities.ProjecT.RBEntity
07-7-18 14:23:30 (I) Ejb3Configuration.scanForClasses :
found EJB3
Entity bean: bg......entities.ProjectT2.TUEntity
2007-7-18 14:23:30 org.hibernate.cfg.AnnotationBinder
bindClass
INFO: Binding entity from annotated class:
bg......entities.ProjecT.RBEntity
2007-7-18 14:23:30 org.hibernate.cfg.annotations.QueryBinder
bindQuery
INFO: Binding Named query: RBEntity.findByloginAndPassword
=> SELECT o
FROM RBEntity WHERE o.anmeldname = :userName AND o.kennwort
= :password
2007-7-18 14:23:30
org.hibernate.cfg.annotations.EntityBinder bindTable
INFO: Bind entity bg......entities.ProjecT.RBEntity on table
RB
2007-7-18 14:23:30 org.hibernate.cfg.AnnotationBinder
bindClass
INFO: Binding entity from annotated class:
bg......entities.ProjectT2.TUEntity
07-7-18 14:23:30 (S) DirectoryDeployerMonitor.init : Cannot
scan for new
archives
org.objectweb.easybeans.server.EmbeddedException:
RuntimeException when
deploying the deployable
'EARDeployableImpl[archive=....apache-tomcat-6.0.13-EBeasy
beans-deplo
ProjecT-EAR.ear]'
at
org.objectweb.easybeans.server.DirectoryDeployerMonitor.dete
ctNewArchives(DirectoryDeployerMonitor.java:257)
at
org.objectweb.easybeans.server.DirectoryDeployerMonitor.init
(DirectoryDeployerMonitor.java:136)
at
org.objectweb.easybeans.server.Embedded.start(Embedded.java:
296)
at
org.objectweb.easybeans.server.war.EasyBeansContextListener.
contextInitialized(EasyBeansContextListener.java:168)
at
org.apache.catalina.core.StandardContext.listenerStart(Stand
ardContext.java:3827)
at
org.apache.catalina.core.StandardContext.start(StandardConte
xt.java:4334)
at
org.apache.catalina.core.ContainerBase.addChildInternal(Cont
ainerBase.java:791)
at
org.apache.catalina.core.ContainerBase.addChild(ContainerBas
e.java:771)
at
org.apache.catalina.core.StandardHost.addChild(StandardHost.
java:525)
at
org.apache.catalina.startup.HostConfig.deployDescriptor(Host
Config.java:626)
at
org.apache.catalina.startup.HostConfig.deployDescriptors(Hos
tConfig.java:553)
at
org.apache.catalina.startup.HostConfig.deployApps(HostConfig
.java:488)
at
org.apache.catalina.startup.HostConfig.start(HostConfig.java
:1138)
at
org.apache.catalina.startup.HostConfig.lifecycleEvent(HostCo
nfig.java:311)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent
(LifecycleSupport.java:117)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.j
ava:1053)
at
org.apache.catalina.core.StandardHost.start(StandardHost.jav
a:719)
at
org.apache.catalina.core.ContainerBase.start(ContainerBase.j
ava:1045)
at
org.apache.catalina.core.StandardEngine.start(StandardEngine
.java:443)
at
org.apache.catalina.core.StandardService.start(StandardServi
ce.java:516)
at
org.apache.catalina.core.StandardServer.start(StandardServer
.java:710)
at
org.apache.catalina.startup.Catalina.start(Catalina.java:566
)
at
sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce
ssorImpl.java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe
thodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:2
88)
at
org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:41
3)
Caused by: org.hibernate.cfg.NotYetImplementedException:
Pure native
scalar queries are not yet supported
at
org.hibernate.cfg.annotations.QueryBinder.bindNativeQuery(Qu
eryBinder.java:118)
at
org.hibernate.cfg.annotations.QueryBinder.bindNativeQueries(
QueryBinder.java:197)
at
org.hibernate.cfg.AnnotationBinder.bindQueries(AnnotationBin
der.java:287)
at
org.hibernate.cfg.AnnotationBinder.bindClass(AnnotationBinde
r.java:417)
at
org.hibernate.cfg.AnnotationConfiguration.processArtifactsOf
Type(AnnotationConfiguration.java:498)
at
org.hibernate.cfg.AnnotationConfiguration.secondPassCompile(
AnnotationConfiguration.java:277)
at
org.hibernate.cfg.Configuration.buildMappings(Configuration.
java:1115)
at
org.hibernate.ejb.Ejb3Configuration.buildMappings(Ejb3Config
uration.java:1269)
at
org.hibernate.ejb.EventListenerConfigurator.configure(EventL
istenerConfigurator.java:150)
at
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configurat
ion.java:888)
at
org.hibernate.ejb.Ejb3Configuration.configure(Ejb3Configurat
ion.java:416)
at
org.hibernate.ejb.HibernatePersistence.createContainerEntity
ManagerFactory(HibernatePersistence.java:126)
at
org.objectweb.easybeans.persistence.JPersistenceContext.init
(JPersistenceContext.java:72)
at
org.objectweb.easybeans.persistence.JPersistenceContext.<
init>(JPersistenceContext.java:65)
at
org.objectweb.easybeans.persistence.PersistenceUnitManager.&
lt;init>(PersistenceUnitManager.java:60)
at
org.objectweb.easybeans.persistence.xml.PersistenceXmlFileAn
alyzer.analyzePersistenceXmlFile(PersistenceXmlFileAnalyzer.
java:139)
at
org.objectweb.easybeans.deployer.AbsWebContainerDeployer.dep
loyEAR(AbsWebContainerDeployer.java:155)
at
org.objectweb.easybeans.deployer.TomcatDeployer.deploy(Tomca
tDeployer.java:195)
at
org.objectweb.easybeans.server.DirectoryDeployerMonitor.dete
ctNewArchives(DirectoryDeployerMonitor.java:249)
... 27 more
I will be happy to see your comments about this exceptions
Greetings,
G.Dimitrov
--
http://www.fastmail.fm
- mmm... Fastmail...
|