You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@tomee.apache.org by nj00yy_1 <78...@qq.com> on 2012/03/20 08:08:59 UTC
3 questions for deploying ear on top of TomEE
Hi Users,
I got apache-tomee-1.0.0-beta-2-webprofile.zip from
http://openejb.apache.org/downloads.html. It's tomcat 7 with openejb.
What I want to do is to deploy a ear directory to $CATALINA_BASE/webapps. My
ear directory works fine with weblogic 11g and Glassfish 3. It confirms to
J2ee 5 standard. I want to make it work with the latest TomEE.
I copied the ear directory to $CATALINA_BASE/webapps and start the server.
But I got the following error when I access my app via
http://localhost:8080/myapp
"SEVERE: Servlet.service() for servlet [uix] in context with path
[/mobile/console] threw exception [Servlet execution threw an exception]
with root cause
java.lang.NoClassDefFoundError: javax.servlet.http.HttpSession"
The issue is not reproduced if I shutdown and start the server for 3-4
times. (I didn't make any change to the server configuration or my ear
directory.) But it's reproduce it again.
I checked that I have servlet-api.jar in $CATALINA_BASE/lib, and
servlet-api.jar doesn't exist in jre/lib, jre/lib/ext or
$CATALINA_BASE/webapps/myapp/WEB-INF/lib.
So I have 3 questions:
(1) How to deploy a ear directory on Tomcat 7 with openejb?
(2) Is the issue I described above a bug in Tomcat 7?
(3) If the structure of my ear directory is like this, how are the jars in
/lib directory loaded in Tomcat 7?
+ App1
+ WEB-INF
+ web.xml
+ lib
+ lib
+ META-INF
+ application.xml
+ App2
+ WEB-INF
+ web.xml
-------------------------------------------------
The following is the content of application.xml.
<?xml version = '1.0' encoding = 'UTF-8'?>
MyApp
Application description
lib
App1
/MyApp/App1
App2
/MyApp
---------------------------------------------------
Thanks a lot!
Regards,
Yan
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4487873.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
Yes, I removed the TomEE server and unzipped a new copy of TomEE server. So
it's a clean environment. And I copy my app ear to webapps/ directory. I
checked no reference and no zip file this time.
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491920.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
did you clean conf/catalina and work/catalina?
- Romain
2012/3/21 nj00yy_1 <78...@qq.com>
> I did have a zip in webapps/. I think that's why I got
> "org.apache.openejb.config.UnknownModuleTypeException: Unable to determine
> module type for jar:".
>
> After I removed that zip file, I checked there is no zip file in my ear and
> no reference to zip file in my xml files. I tried to deploy my ear but I
> still got "java.lang.IllegalStateException: zip file closed".
>
> Do I need to do some configuration of TomEE before I deploy my ear ?
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491850.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
I did have a zip in webapps/. I think that's why I got
"org.apache.openejb.config.UnknownModuleTypeException: Unable to determine
module type for jar:".
After I removed that zip file, I checked there is no zip file in my ear and
no reference to zip file in my xml files. I tried to deploy my ear but I
still got "java.lang.IllegalStateException: zip file closed".
Do I need to do some configuration of TomEE before I deploy my ear ?
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491850.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
if the zip doesn't exist it is referenced somewhere, maybe server.xml?
- Romain
2012/3/21 nj00yy_1 <78...@qq.com>
> Any help for the following error? I don't have a myapp.zip.
>
> WARN - Error deploying application
> Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp
> java.lang.IllegalStateException: zip file closed
> at java.util.zip.ZipFile.ensureOpen(ZipFile.java:416)
> at java.util.zip.ZipFile.getEntry(ZipFile.java:161)
> at java.util.jar.JarFile.getEntry(JarFile.java:208)
> at java.util.jar.JarFile.getJarEntry(JarFile.java:191)
> at
> sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:757)
> at
> sun.misc.URLClassPath$JarLoader.findResource(URLClassPath.java:735)
> at sun.misc.URLClassPath.findResource(URLClassPath.java:146)
> at java.net.URLClassLoader$2.run(URLClassLoader.java:385)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findResource(URLClassLoader.java:382)
> at java.lang.ClassLoader.getResource(ClassLoader.java:1003)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at
> org.apache.openejb.config.ReadDescriptors.getUrl(ReadDescriptors.java:210)
> at
>
> org.apache.openejb.config.ReadDescriptors.readValidationConfigType(ReadDescriptors.java:245)
> at
> org.apache.openejb.config.ReadDescriptors.deploy(ReadDescriptors.java:91)
> at
>
> org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:263)
> at
>
> org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:693)
> at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:983)
> at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
> at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
> at
>
> org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
> at java.lang.Thread.run(Thread.java:662)
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491589.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
Any help for the following error? I don't have a myapp.zip.
WARN - Error deploying application
Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp
java.lang.IllegalStateException: zip file closed
at java.util.zip.ZipFile.ensureOpen(ZipFile.java:416)
at java.util.zip.ZipFile.getEntry(ZipFile.java:161)
at java.util.jar.JarFile.getEntry(JarFile.java:208)
at java.util.jar.JarFile.getJarEntry(JarFile.java:191)
at sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:757)
at sun.misc.URLClassPath$JarLoader.findResource(URLClassPath.java:735)
at sun.misc.URLClassPath.findResource(URLClassPath.java:146)
at java.net.URLClassLoader$2.run(URLClassLoader.java:385)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findResource(URLClassLoader.java:382)
at java.lang.ClassLoader.getResource(ClassLoader.java:1003)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at
org.apache.openejb.config.ReadDescriptors.getUrl(ReadDescriptors.java:210)
at
org.apache.openejb.config.ReadDescriptors.readValidationConfigType(ReadDescriptors.java:245)
at
org.apache.openejb.config.ReadDescriptors.deploy(ReadDescriptors.java:91)
at
org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:263)
at
org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:693)
at
org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:983)
at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
at java.lang.Thread.run(Thread.java:662)
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491589.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
file Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/webapps/myapp.zip
doesn't exist?
- Romain
2012/3/21 nj00yy_1 <78...@qq.com>
> I have an warning while deploying my app.
> The following is the stack. I don't understand it said "deploying
> myapp.zip"
> but I just copy my ear directory to webapps\myapp, I didn't provide a zip.
>
> 2012-03-21 01:44:30,287 - WARN - Error deploying application
> Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp
> java.lang.IllegalStateException: zip file closed
> at java.util.zip.ZipFile.ensureOpen(ZipFile.java:416)
> at java.util.zip.ZipFile.getEntry(ZipFile.java:161)
> at java.util.jar.JarFile.getEntry(JarFile.java:208)
> at java.util.jar.JarFile.getJarEntry(JarFile.java:191)
> at
> sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:757)
> at
> sun.misc.URLClassPath$JarLoader.findResource(URLClassPath.java:735)
> at sun.misc.URLClassPath.findResource(URLClassPath.java:146)
> at java.net.URLClassLoader$2.run(URLClassLoader.java:385)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findResource(URLClassLoader.java:382)
> at java.lang.ClassLoader.getResource(ClassLoader.java:1003)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at
> org.apache.openejb.config.ReadDescriptors.getUrl(ReadDescriptors.java:210)
> at
>
> org.apache.openejb.config.ReadDescriptors.readValidationConfigType(ReadDescriptors.java:245)
> at
> org.apache.openejb.config.ReadDescriptors.deploy(ReadDescriptors.java:91)
> at
>
> org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:263)
> at
>
> org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:693)
> at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:983)
> at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
> at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
> at
>
> org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
> at java.lang.Thread.run(Thread.java:662)
> 2012-03-21 01:44:30,287 - WARN - Error deploying application
> Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp
> java.lang.IllegalStateException: zip file closed
> at java.util.zip.ZipFile.ensureOpen(ZipFile.java:416)
> at java.util.zip.ZipFile.getEntry(ZipFile.java:161)
> at java.util.jar.JarFile.getEntry(JarFile.java:208)
> at java.util.jar.JarFile.getJarEntry(JarFile.java:191)
> at
> sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:757)
> at
> sun.misc.URLClassPath$JarLoader.findResource(URLClassPath.java:735)
> at sun.misc.URLClassPath.findResource(URLClassPath.java:146)
> at java.net.URLClassLoader$2.run(URLClassLoader.java:385)
> at java.security.AccessController.doPrivileged(Native Method)
> at java.net.URLClassLoader.findResource(URLClassLoader.java:382)
> at java.lang.ClassLoader.getResource(ClassLoader.java:1003)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at java.lang.ClassLoader.getResource(ClassLoader.java:998)
> at
> org.apache.openejb.config.ReadDescriptors.getUrl(ReadDescriptors.java:210)
> at
>
> org.apache.openejb.config.ReadDescriptors.readValidationConfigType(ReadDescriptors.java:245)
> at
> org.apache.openejb.config.ReadDescriptors.deploy(ReadDescriptors.java:91)
> at
>
> org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:263)
> at
>
> org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:693)
> at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:983)
> at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
> at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
> at
>
> org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
> at java.lang.Thread.run(Thread.java:662)
> 2012-03-21 01:44:33,287 - WARN - Error deploying application
> Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp.zip
> org.apache.openejb.config.UnknownModuleTypeException: Unable to determine
> module type for jar:
>
> file:/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/webapps/myapp.zip:
> Unknown module type:
>
> url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
> at
> org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:141)
> at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:951)
> at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
> at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
> at
>
> org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
> at java.lang.Thread.run(Thread.java:662)
> Caused by: org.apache.openejb.config.UnknownModuleTypeException: Unknown
> module type:
>
> url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
> at
>
> org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1572)
> at
>
> org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1500)
> at
> org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:139)
> ... 9 more
> 2012-03-21 01:44:33,287 - WARN - Error deploying application
> Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp.zip
> org.apache.openejb.config.UnknownModuleTypeException: Unable to determine
> module type for jar:
>
> file:/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/webapps/myapp.zip:
> Unknown module type:
>
> url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
> at
> org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:141)
> at
>
> org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:951)
> at
>
> org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
> at
>
> org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
> at
>
> org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
> at
>
> org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
> at
>
> org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
> at java.lang.Thread.run(Thread.java:662)
> Caused by: org.apache.openejb.config.UnknownModuleTypeException: Unknown
> module type:
>
> url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
> at
>
> org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1572)
> at
>
> org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1500)
> at
> org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:139)
> ... 9 more
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491553.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
I have an warning while deploying my app.
The following is the stack. I don't understand it said "deploying myapp.zip"
but I just copy my ear directory to webapps\myapp, I didn't provide a zip.
2012-03-21 01:44:30,287 - WARN - Error deploying application
Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp
java.lang.IllegalStateException: zip file closed
at java.util.zip.ZipFile.ensureOpen(ZipFile.java:416)
at java.util.zip.ZipFile.getEntry(ZipFile.java:161)
at java.util.jar.JarFile.getEntry(JarFile.java:208)
at java.util.jar.JarFile.getJarEntry(JarFile.java:191)
at sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:757)
at sun.misc.URLClassPath$JarLoader.findResource(URLClassPath.java:735)
at sun.misc.URLClassPath.findResource(URLClassPath.java:146)
at java.net.URLClassLoader$2.run(URLClassLoader.java:385)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findResource(URLClassLoader.java:382)
at java.lang.ClassLoader.getResource(ClassLoader.java:1003)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at
org.apache.openejb.config.ReadDescriptors.getUrl(ReadDescriptors.java:210)
at
org.apache.openejb.config.ReadDescriptors.readValidationConfigType(ReadDescriptors.java:245)
at
org.apache.openejb.config.ReadDescriptors.deploy(ReadDescriptors.java:91)
at
org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:263)
at
org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:693)
at
org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:983)
at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
at java.lang.Thread.run(Thread.java:662)
2012-03-21 01:44:30,287 - WARN - Error deploying application
Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp
java.lang.IllegalStateException: zip file closed
at java.util.zip.ZipFile.ensureOpen(ZipFile.java:416)
at java.util.zip.ZipFile.getEntry(ZipFile.java:161)
at java.util.jar.JarFile.getEntry(JarFile.java:208)
at java.util.jar.JarFile.getJarEntry(JarFile.java:191)
at sun.misc.URLClassPath$JarLoader.getResource(URLClassPath.java:757)
at sun.misc.URLClassPath$JarLoader.findResource(URLClassPath.java:735)
at sun.misc.URLClassPath.findResource(URLClassPath.java:146)
at java.net.URLClassLoader$2.run(URLClassLoader.java:385)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findResource(URLClassLoader.java:382)
at java.lang.ClassLoader.getResource(ClassLoader.java:1003)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at java.lang.ClassLoader.getResource(ClassLoader.java:998)
at
org.apache.openejb.config.ReadDescriptors.getUrl(ReadDescriptors.java:210)
at
org.apache.openejb.config.ReadDescriptors.readValidationConfigType(ReadDescriptors.java:245)
at
org.apache.openejb.config.ReadDescriptors.deploy(ReadDescriptors.java:91)
at
org.apache.openejb.config.ConfigurationFactory$Chain.deploy(ConfigurationFactory.java:263)
at
org.apache.openejb.config.ConfigurationFactory.configureApplication(ConfigurationFactory.java:693)
at
org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:983)
at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
at java.lang.Thread.run(Thread.java:662)
2012-03-21 01:44:33,287 - WARN - Error deploying application
Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp.zip
org.apache.openejb.config.UnknownModuleTypeException: Unable to determine
module type for jar:
file:/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/webapps/myapp.zip:
Unknown module type:
url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
at
org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:141)
at
org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:951)
at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.apache.openejb.config.UnknownModuleTypeException: Unknown
module type:
url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
at
org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1572)
at
org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1500)
at
org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:139)
... 9 more
2012-03-21 01:44:33,287 - WARN - Error deploying application
Z:\software\tomee\apache-tomee-webprofile-1.0.0-beta-2\webapps\myapp.zip
org.apache.openejb.config.UnknownModuleTypeException: Unable to determine
module type for jar:
file:/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/webapps/myapp.zip:
Unknown module type:
url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
at
org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:141)
at
org.apache.tomee.catalina.TomcatWebAppBuilder.checkHost(TomcatWebAppBuilder.java:951)
at
org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:123)
at
org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119)
at
org.apache.catalina.util.LifecycleBase.fireLifecycleEvent(LifecycleBase.java:90)
at
org.apache.catalina.core.ContainerBase.backgroundProcess(ContainerBase.java:1242)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1400)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.processChildren(ContainerBase.java:1410)
at
org.apache.catalina.core.ContainerBase$ContainerBackgroundProcessor.run(ContainerBase.java:1389)
at java.lang.Thread.run(Thread.java:662)
Caused by: org.apache.openejb.config.UnknownModuleTypeException: Unknown
module type:
url=/Z:/software/tomee/apache-tomee-webprofile-1.0.0-beta-2/temp/AppModule-7644132466397362598
at
org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1572)
at
org.apache.openejb.config.DeploymentLoader.discoverModuleType(DeploymentLoader.java:1500)
at
org.apache.openejb.config.DeploymentLoader.load(DeploymentLoader.java:139)
... 9 more
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491553.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
do you still have the classnotfounderror?
if an exception is thrown while the app is deployed it will be
automatically undeployed.
- Romain
2012/3/21 nj00yy_1 <78...@qq.com>
> Hi Romain,
>
> The structure of my ear directory is like this:
> + App1
> + WEB-INF
> + web.xml
> + lib
> + lib
> + META-INF
> + application.xml
> + App2
> + WEB-INF
> + web.xml
>
> I found TomEE server first deploy App2 and then App1, and after server
> starts, I got the info:
> "The destroy() method was called on component
> [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/App1]]
> after destroy() had already been called. "
>
> I want to why destroy() method was called on that component? I didn't do
> anything to undeploy or delete.
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491468.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
Hi Romain,
The structure of my ear directory is like this:
+ App1
+ WEB-INF
+ web.xml
+ lib
+ lib
+ META-INF
+ application.xml
+ App2
+ WEB-INF
+ web.xml
I found TomEE server first deploy App2 and then App1, and after server
starts, I got the info:
"The destroy() method was called on component
[StandardEngine[Catalina].StandardHost[localhost].StandardContext[/App1]]
after destroy() had already been called. "
I want to why destroy() method was called on that component? I didn't do
anything to undeploy or delete.
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4491468.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
put it in CATALINA_OPTS instead of JAVA_OPTS
- Romain
2012/3/20 nj00yy_1 <78...@qq.com>
> Hi Romain ,
>
> I tried to add -Dcom.sun.management.jmxremote before start server so that I
> can use jconsole to monitor it locally.
> I tried to add "set JAVA_OPTS=-Dcom.sun.management.jmxremote" at the
> beginning of cataline.bat,
> or set set JAVA_OPTS=-Dcom.sun.management.jmxremote in command window
> before
> I ran startup.bat. However, none of them work. Did I miss anything?
>
> -Yan
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488236.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
Hi Romain ,
I tried to add -Dcom.sun.management.jmxremote before start server so that I
can use jconsole to monitor it locally.
I tried to add "set JAVA_OPTS=-Dcom.sun.management.jmxremote" at the
beginning of cataline.bat,
or set set JAVA_OPTS=-Dcom.sun.management.jmxremote in command window before
I ran startup.bat. However, none of them work. Did I miss anything?
-Yan
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488236.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
use catalina opts:
export CATALINA_OPTS="-Xmx512m"
- Romain
2012/3/20 nj00yy_1 <78...@qq.com>
> Hi Romain
>
> I got java.lang.OutOfMemoryError: PermGen space when deploying my app. Is
> there any way to set jvm with large memory size before start tomEE server?
>
> -Yan
>
>
> ------------------ Original ------------------
> From: "Romain Manni-Bucau [via OpenEJB]"<
> ml-node+s979440n4488079h0@n4.nabble.com>;
> Date: Tue, Mar 20, 2012 04:53 PM
> To: "nj00yy_1"<78...@qq.com>;
>
> Subject: Re: 3 questions for deploying ear on top of TomEE
>
>
> maybe look in jconsole where it stucks (in thread tab).
>
> - Romain
>
>
> 2012/3/20 nj00yy_1 <[hidden email]>
>
> > Hi,
> >
> > I cannot provide a sample to reproduce right now.
> >
> > However, I do have another issue.
> > If I copy all the jars in MyApp/lib to MyApp/App1/WEB-INF/lib, and delete
> > <library-directory>lib</library-directory> in the application.xml, then
> > re-start the server.
> > The server stucked at "INFO: Deploying web application directory MyApp
> > TomcatWebAppBuilder.start /MyApp"
> >
> > I think it should work. Do you have any suggestion for this issue?
> Thanks!
> >
> > Yan
> >
> >
> > --
> > View this message in context:
> >
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488043.html
> > Sent from the OpenEJB User mailing list archive at Nabble.com.
> >
>
>
>
>
> If you reply to this email, your message will be
> added to the discussion below:
>
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488079.html
> To unsubscribe from 3 questions for
> deploying ear on top of TomEE, click here.
> NAML
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488150.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
Hi Romain
I got java.lang.OutOfMemoryError: PermGen space when deploying my app. Is there any way to set jvm with large memory size before start tomEE server?
-Yan
------------------ Original ------------------
From: "Romain Manni-Bucau [via OpenEJB]"<ml...@n4.nabble.com>;
Date: Tue, Mar 20, 2012 04:53 PM
To: "nj00yy_1"<78...@qq.com>;
Subject: Re: 3 questions for deploying ear on top of TomEE
maybe look in jconsole where it stucks (in thread tab).
- Romain
2012/3/20 nj00yy_1 <[hidden email]>
> Hi,
>
> I cannot provide a sample to reproduce right now.
>
> However, I do have another issue.
> If I copy all the jars in MyApp/lib to MyApp/App1/WEB-INF/lib, and delete
> <library-directory>lib</library-directory> in the application.xml, then
> re-start the server.
> The server stucked at "INFO: Deploying web application directory MyApp
> TomcatWebAppBuilder.start /MyApp"
>
> I think it should work. Do you have any suggestion for this issue? Thanks!
>
> Yan
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488043.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
If you reply to this email, your message will be added to the discussion below:
http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488079.html
To unsubscribe from 3 questions for deploying ear on top of TomEE, click here.
NAML
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488150.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
maybe look in jconsole where it stucks (in thread tab).
- Romain
2012/3/20 nj00yy_1 <78...@qq.com>
> Hi,
>
> I cannot provide a sample to reproduce right now.
>
> However, I do have another issue.
> If I copy all the jars in MyApp/lib to MyApp/App1/WEB-INF/lib, and delete
> <library-directory>lib</library-directory> in the application.xml, then
> re-start the server.
> The server stucked at "INFO: Deploying web application directory MyApp
> TomcatWebAppBuilder.start /MyApp"
>
> I think it should work. Do you have any suggestion for this issue? Thanks!
>
> Yan
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488043.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
Hi,
I cannot provide a sample to reproduce right now.
However, I do have another issue.
If I copy all the jars in MyApp/lib to MyApp/App1/WEB-INF/lib, and delete
<library-directory>lib</library-directory> in the application.xml, then
re-start the server.
The server stucked at "INFO: Deploying web application directory MyApp
TomcatWebAppBuilder.start /MyApp"
I think it should work. Do you have any suggestion for this issue? Thanks!
Yan
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4488043.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
1) when the app is deployed a classloader is created with lib + ejbmodules
jars. then it is set as parent of webapps.
2) noclassdeffound on javax.servlet.http.HttpSession is more an issue since
it is in tomcat lib so in the upper classloader. It is probably linked to
your app. You should provide us a sample to reproduce if you want any help.
- Romain
2012/3/20 nj00yy_1 <78...@qq.com>
> (1) Actually, I found the jars in MyApp/lib are not loaded correctly. I
> have
> some jars files in MyApp/lib. When I access MyApp, it reported some jar
> files were missing. So I copied the related jars from MyApp/lib to
> MyApp/App1/WEB-INF/lib. Then the error message for class not found was
> gone.
> So I want to know how the jars in MyApp/lib are loaded in to server.
>
> (2) The following is the stack for java.lang.NoClassDefFoundError:
> javax.servlet.http.HttpSession
> Mar 19, 2012 9:47:04 PM org.apache.catalina.core.StandardWrapperValve
> invoke
> SEVERE: Servlet.service() for servlet [uix] in context with path
> [/MyApp/App1] threw exception [Servlet execution threw an exception] with
> root cause
> java.lang.NoClassDefFoundError: javax.servlet.http.HttpSession
> at oracle.cabo.servlet.BaseBajaContext.class$(Unknown Source)
> at oracle.cabo.servlet.BaseBajaContext.getService(Unknown Source)
> at oracle.cabo.servlet.PageBrokerHandler.handleRequest(Unknown
> Source)
> at oracle.cabo.servlet.UIXServlet.doGet(Unknown Source)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
> at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
> at
>
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:304)
> at
>
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
> at oracle.lite.web.CheckSessionFilter.doFilter(Unknown Source)
> at
>
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
> at
>
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
> at
>
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
> at
>
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:185)
> at
> org.apache.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)
> at
>
> org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
> at
>
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:151)
> at
>
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
> at
> org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:929)
> at
>
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
> at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:405)
> at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:269)
> at
>
> org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:515)
> at
>
> org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:302)
> at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
> at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
> at java.lang.Thread.run(Thread.java:662)
>
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4487954.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.
>
Re: 3 questions for deploying ear on top of TomEE
Posted by nj00yy_1 <78...@qq.com>.
(1) Actually, I found the jars in MyApp/lib are not loaded correctly. I have
some jars files in MyApp/lib. When I access MyApp, it reported some jar
files were missing. So I copied the related jars from MyApp/lib to
MyApp/App1/WEB-INF/lib. Then the error message for class not found was gone.
So I want to know how the jars in MyApp/lib are loaded in to server.
(2) The following is the stack for java.lang.NoClassDefFoundError:
javax.servlet.http.HttpSession
Mar 19, 2012 9:47:04 PM org.apache.catalina.core.StandardWrapperValve invoke
SEVERE: Servlet.service() for servlet [uix] in context with path
[/MyApp/App1] threw exception [Servlet execution threw an exception] with
root cause
java.lang.NoClassDefFoundError: javax.servlet.http.HttpSession
at oracle.cabo.servlet.BaseBajaContext.class$(Unknown Source)
at oracle.cabo.servlet.BaseBajaContext.getService(Unknown Source)
at oracle.cabo.servlet.PageBrokerHandler.handleRequest(Unknown Source)
at oracle.cabo.servlet.UIXServlet.doGet(Unknown Source)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:304)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at oracle.lite.web.CheckSessionFilter.doFilter(Unknown Source)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:224)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:185)
at org.apache.tomee.catalina.OpenEJBValve.invoke(OpenEJBValve.java:44)
at
org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:151)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:100)
at
org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:929)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:405)
at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:269)
at
org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:515)
at
org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:302)
at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
at java.lang.Thread.run(Thread.java:662)
--
View this message in context: http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4487954.html
Sent from the OpenEJB User mailing list archive at Nabble.com.
Re: 3 questions for deploying ear on top of TomEE
Posted by Romain Manni-Bucau <rm...@gmail.com>.
Hi,
can you paste the whole stacktrace please?
normally tomee loads it correctly. I recently fixed on trunk issue with
ejbs in lib/ but i guess it is not your issue.
any source/binary to reproduce your issue?
- Romain
2012/3/20 nj00yy_1 <78...@qq.com>
> Hi Users,
>
> I got apache-tomee-1.0.0-beta-2-webprofile.zip from
> http://openejb.apache.org/downloads.html. It's tomcat 7 with openejb.
> What I want to do is to deploy a ear directory to $CATALINA_BASE/webapps.
> My
> ear directory works fine with weblogic 11g and Glassfish 3. It confirms to
> J2ee 5 standard. I want to make it work with the latest TomEE.
>
> I copied the ear directory to $CATALINA_BASE/webapps and start the server.
> But I got the following error when I access my app via
> http://localhost:8080/myapp
> "SEVERE: Servlet.service() for servlet [uix] in context with path
> [/mobile/console] threw exception [Servlet execution threw an exception]
> with root cause
> java.lang.NoClassDefFoundError: javax.servlet.http.HttpSession"
>
> The issue is not reproduced if I shutdown and start the server for 3-4
> times. (I didn't make any change to the server configuration or my ear
> directory.) But it's reproduce it again.
> I checked that I have servlet-api.jar in $CATALINA_BASE/lib, and
> servlet-api.jar doesn't exist in jre/lib, jre/lib/ext or
> $CATALINA_BASE/webapps/myapp/WEB-INF/lib.
>
> So I have 3 questions:
> (1) How to deploy a ear directory on Tomcat 7 with openejb?
> (2) Is the issue I described above a bug in Tomcat 7?
> (3) If the structure of my ear directory is like this, how are the jars in
> /lib directory loaded in Tomcat 7?
> + App1
> + WEB-INF
> + web.xml
> + lib
> + lib
> + META-INF
> + application.xml
> + App2
> + WEB-INF
> + web.xml
> -------------------------------------------------
> The following is the content of application.xml.
> <?xml version = '1.0' encoding = 'UTF-8'?>
>
> MyApp
> Application description
> lib
>
>
> App1
> /MyApp/App1
>
>
>
>
> App2
> /MyApp
>
>
>
> ---------------------------------------------------
> Thanks a lot!
>
> Regards,
> Yan
>
>
> --
> View this message in context:
> http://openejb.979440.n4.nabble.com/3-questions-for-deploying-ear-on-top-of-TomEE-tp4487873p4487873.html
> Sent from the OpenEJB User mailing list archive at Nabble.com.