[jira] [Commented] (TOMEE-223) An archive artifact is not deployed when using deployment descriptor
[ https://issues.apache.org/jira/browse/TOMEE-223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573302#comment-13573302 ] Michael Golubev commented on TOMEE-223: --- No, I have just one webapp to be deployed with ROOT context. I use 'apache-tomee-plus-1.5.1' installation and it looks like it doesn't have a webapp to be deployed with ROOT context. So, if I don't add my own webapp to be deployed with ROOT context, I can't see any webapp under the ROOT context (accessing ROOT context over http returns 404, can't see a MBean of the webapp with ROOT context via jconsole e.t.c.). An archive artifact is not deployed when using deployment descriptor Key: TOMEE-223 URL: https://issues.apache.org/jira/browse/TOMEE-223 Project: TomEE Issue Type: Bug Reporter: Michael Golubev Attachments: sample-ear-and-war.zip I experience problems with deployment of archive artifacts (WARs and EARs) to TomEE 1.0.0. An archive artifact is not deployed (as I expect) when deployment descriptor is placed into TomEE home/conf/Catalina/localhost folder. Exactly the same workflow works for exploded artifacts. Exactly the same workflow (for WAR's) works for both archive and exploded artifcats in just-a-Tomcat. I am developing an integration for TomEE and IntelliJ IDEA and can not easily workaround by using different deployment methods. WAR case: - deployment descriptor: ?xml version=1.0 encoding=UTF-8? Context path=/myWarCtx docBase=C:\path\to\myWar.war / - error message: java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/myWarCtx]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:898) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:649) at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1585) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) 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) EAR case: - deployment descriptor: ?xml version=1.0 encoding=UTF-8? Context docBase=C:\path\to\myEar.ear / - error message: java.lang.IllegalArgumentException: Document base C:\path\to\myEar.ear does not exist or is not a readable directory at org.apache.naming.resources.FileDirContext.setDocBase(FileDirContext.java:140) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:4894) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5074) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:649) at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1585) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) 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) WAR case looks like obvious downgrade from essential Tomcat, since deployment with the sample deployment descriptor on Tomcat is successful. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (TOMEE-223) An archive artifact is not deployed when using deployment descriptor
[ https://issues.apache.org/jira/browse/TOMEE-223?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573306#comment-13573306 ] Romain Manni-Bucau commented on TOMEE-223: -- Hmm, you use tomee 1.5.1? thought it was the snapshot, if so can you try the snapshot please? PS: i'm on freenode #openejb if you want An archive artifact is not deployed when using deployment descriptor Key: TOMEE-223 URL: https://issues.apache.org/jira/browse/TOMEE-223 Project: TomEE Issue Type: Bug Reporter: Michael Golubev Attachments: sample-ear-and-war.zip I experience problems with deployment of archive artifacts (WARs and EARs) to TomEE 1.0.0. An archive artifact is not deployed (as I expect) when deployment descriptor is placed into TomEE home/conf/Catalina/localhost folder. Exactly the same workflow works for exploded artifacts. Exactly the same workflow (for WAR's) works for both archive and exploded artifcats in just-a-Tomcat. I am developing an integration for TomEE and IntelliJ IDEA and can not easily workaround by using different deployment methods. WAR case: - deployment descriptor: ?xml version=1.0 encoding=UTF-8? Context path=/myWarCtx docBase=C:\path\to\myWar.war / - error message: java.lang.IllegalStateException: ContainerBase.addChild: start: org.apache.catalina.LifecycleException: Failed to start component [StandardEngine[Catalina].StandardHost[localhost].StandardContext[/myWarCtx]] at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:898) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:649) at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1585) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) 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) EAR case: - deployment descriptor: ?xml version=1.0 encoding=UTF-8? Context docBase=C:\path\to\myEar.ear / - error message: java.lang.IllegalArgumentException: Document base C:\path\to\myEar.ear does not exist or is not a readable directory at org.apache.naming.resources.FileDirContext.setDocBase(FileDirContext.java:140) at org.apache.catalina.core.StandardContext.resourcesStart(StandardContext.java:4894) at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5074) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:895) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:871) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:615) at org.apache.catalina.startup.HostConfig.deployDescriptor(HostConfig.java:649) at org.apache.catalina.startup.HostConfig$DeployDescriptor.run(HostConfig.java:1585) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) at java.util.concurrent.FutureTask.run(FutureTask.java:138) 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) WAR case looks like obvious downgrade from essential Tomcat, since deployment with the sample deployment descriptor on Tomcat is successful. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Created] (TOMEE-760) CdiEjbBean are not passivationcapable
Romain Manni-Bucau created TOMEE-760: Summary: CdiEjbBean are not passivationcapable Key: TOMEE-760 URL: https://issues.apache.org/jira/browse/TOMEE-760 Project: TomEE Issue Type: Bug Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Created] (OPENEJB-1997) warning/exception at server start about META-INF
Lars Herschke created OPENEJB-1997: -- Summary: warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Created] (TOMEE-761) org.apache.cxf.transport.endpoint.address not set on request for rest endpoints (means the host/port are not dynamic in UriInfo)
Romain Manni-Bucau created TOMEE-761: Summary: org.apache.cxf.transport.endpoint.address not set on request for rest endpoints (means the host/port are not dynamic in UriInfo) Key: TOMEE-761 URL: https://issues.apache.org/jira/browse/TOMEE-761 Project: TomEE Issue Type: Bug Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (OPENEJB-1997) warning/exception at server start about META-INF
[ https://issues.apache.org/jira/browse/OPENEJB-1997?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Lars Herschke updated OPENEJB-1997: --- Environment: FreeBSD 6.4-STABLE i386 (was: FreeBSD 6.4-STABLE FreeBSD 6.4-STABLE i386) warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Created] (TOMEE-762) xbean 3.13
Romain Manni-Bucau created TOMEE-762: Summary: xbean 3.13 Key: TOMEE-762 URL: https://issues.apache.org/jira/browse/TOMEE-762 Project: TomEE Issue Type: Dependency upgrade Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 catch NoClassDefFound on getDeclaredmethods getDeclaredFields which is mandatory to be able to deploy skipping not used classes depending on missing deps (spring-data-jpa and querydsl for instance) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (TOMEE-761) org.apache.cxf.transport.endpoint.address not set on request for rest endpoints (means the host/port are not dynamic in UriInfo)
[ https://issues.apache.org/jira/browse/TOMEE-761?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau resolved TOMEE-761. -- Resolution: Fixed org.apache.cxf.transport.endpoint.address not set on request for rest endpoints (means the host/port are not dynamic in UriInfo) Key: TOMEE-761 URL: https://issues.apache.org/jira/browse/TOMEE-761 Project: TomEE Issue Type: Bug Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1443448 - in /tomee/tomee/trunk: ./ container/openejb-core/src/main/java/org/apache/openejb/cdi/ server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/ server/openejb-cxf-r
Author: rmannibucau Date: Thu Feb 7 13:13:21 2013 New Revision: 1443448 URL: http://svn.apache.org/viewvc?rev=1443448view=rev Log: TOMEE-762 TOMEE-761 TOMEE-760 cdiejbbean should be passivation capable + xbean 3.13 + org.apache.cxf.transport.endpoint.address attribute for rest services Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java tomee/tomee/trunk/pom.xml tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/Contexts.java tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/CxfRsHttpListener.java tomee/tomee/trunk/server/openejb-cxf-rs/src/test/java/org/apache/openejb/server/cxf/rs/RsInterceptorInjectionTest.java tomee/tomee/trunk/server/openejb-http/src/main/java/org/apache/openejb/server/httpd/HttpRequestImpl.java Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java?rev=1443448r1=1443447r2=1443448view=diff == --- tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java (original) +++ tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java Thu Feb 7 13:13:21 2013 @@ -41,6 +41,7 @@ import javax.enterprise.inject.spi.Injec import javax.enterprise.inject.spi.SessionBeanType; import javax.persistence.EntityManager; import java.io.Serializable; +import java.lang.annotation.Annotation; import java.lang.reflect.Member; import java.lang.reflect.Method; import java.lang.reflect.UndeclaredThrowableException; @@ -66,6 +67,7 @@ public class CdiEjbBeanT extends BaseE super(beanClass, toSessionType(beanContext.getComponentType()), webBeansContext); this.beanContext = beanContext; beanContext.set(Bean.class, this); +passivatingId = beanContext.getDeploymentID() + getReturnType().getName(); } @Override // copied to be able to produce EM (should be fixed in OWB for next CDI spec) @@ -153,11 +155,6 @@ public class CdiEjbBeanT extends BaseE } @Override -public String getId() { -return beanContext.getDeploymentID() + getReturnType().getName(); -} - -@Override protected void afterConstructor(T instance, CreationalContextT tCreationalContext) { // no-op } @@ -216,23 +213,6 @@ public class CdiEjbBeanT extends BaseE @SuppressWarnings(unchecked) protected T getInstance(final CreationalContextT creationalContext) { return createEjb(creationalContext); - -/* -final T instance; -if (scopeClass == null || Dependent.class == scopeClass) { // no need to add any layer, null = @New -instance = createEjb(creationalContext); -} else { // only stateful normally -final InstanceBeanT bean = new InstanceBeanT(this); -if (webBeansContext.getBeanManagerImpl().isScopeTypeNormal(scopeClass)) { -instance = (T) webBeansContext.getProxyFactory().createNormalScopedBeanProxy(bean, creationalContext); -} else { -final Context context = webBeansContext.getBeanManagerImpl().getContext(scopeClass); -instance = context.get(bean, creationalContext); -} -bean.setOWBProxy(instance); -} -return instance; -*/ } @Override @@ -310,8 +290,9 @@ public class CdiEjbBeanT extends BaseE * @see org.apache.webbeans.component.AbstractBean#isPassivationCapable() */ @Override -public boolean isPassivationCapable() { -return getWebBeansContext().getBeanManagerImpl().isPassivatingScope(getScope()); +public boolean isPassivationCapable() { // dependent means EJB serialization +final Class? extends Annotation scope = getScope(); +return Dependent.class.equals(scope) || getWebBeansContext().getBeanManagerImpl().isPassivatingScope(scope); } @SuppressWarnings(unchecked) Modified: tomee/tomee/trunk/pom.xml URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/pom.xml?rev=1443448r1=1443447r2=1443448view=diff == --- tomee/tomee/trunk/pom.xml (original) +++ tomee/tomee/trunk/pom.xml Thu Feb 7 13:13:21 2013 @@ -97,7 +97,7 @@ maven-bundle-plugin.version2.3.7/maven-bundle-plugin.version !-- This is used by a manifest classpath entry -- -xbeanVersion3.12/xbeanVersion +xbeanVersion3.13-SNAPSHOT/xbeanVersion !-- OSGi bundles properties -- openejb.bundle.activator/ Modified: tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/Contexts.java URL:
[jira] [Resolved] (TOMEE-760) CdiEjbBean are not passivationcapable
[ https://issues.apache.org/jira/browse/TOMEE-760?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau resolved TOMEE-760. -- Resolution: Fixed CdiEjbBean are not passivationcapable - Key: TOMEE-760 URL: https://issues.apache.org/jira/browse/TOMEE-760 Project: TomEE Issue Type: Bug Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (TOMEE-762) xbean 3.13
[ https://issues.apache.org/jira/browse/TOMEE-762?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau resolved TOMEE-762. -- Resolution: Fixed xbean 3.13 -- Key: TOMEE-762 URL: https://issues.apache.org/jira/browse/TOMEE-762 Project: TomEE Issue Type: Dependency upgrade Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 catch NoClassDefFound on getDeclaredmethods getDeclaredFields which is mandatory to be able to deploy skipping not used classes depending on missing deps (spring-data-jpa and querydsl for instance) -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
buildbot failure in ASF Buildbot on tomee-trunk-ubuntu
The Buildbot has detected a new failure on builder tomee-trunk-ubuntu while building ASF Buildbot. Full details are available at: http://ci.apache.org/builders/tomee-trunk-ubuntu/builds/80 Buildbot URL: http://ci.apache.org/ Buildslave for this Build: hemera_ubuntu Build Reason: scheduler Build Source Stamp: [branch tomee/tomee/trunk] 1443448 Blamelist: rmannibucau BUILD FAILED: failed test sincerely, -The Buildbot
[jira] [Commented] (OPENEJB-1997) warning/exception at server start about META-INF
[ https://issues.apache.org/jira/browse/OPENEJB-1997?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573479#comment-13573479 ] Romain Manni-Bucau commented on OPENEJB-1997: - Hi, can you share a sample reproducing it? tested with a META-INF/application.xml and seems fine warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1443471 - /tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java
Author: rmannibucau Date: Thu Feb 7 13:49:25 2013 New Revision: 1443471 URL: http://svn.apache.org/viewvc?rev=1443471view=rev Log: validation of passivation for EJB shouldn't use directly isPassivationCapable but is the scope passivable Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java?rev=1443471r1=1443470r2=1443471view=diff == --- tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java (original) +++ tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java Thu Feb 7 13:49:25 2013 @@ -72,7 +72,8 @@ public class CdiEjbBeanT extends BaseE @Override // copied to be able to produce EM (should be fixed in OWB for next CDI spec) public void validatePassivationDependencies() { -if(isPassivationCapable()) { +// if(isPassivationCapable()) { + if(getWebBeansContext().getBeanManagerImpl().isPassivatingScope(getScope())) { // not @Dependent otherwise we either can't inject EJB in serializable beans or the opposite final SetInjectionPoint beanInjectionPoints = getInjectionPoints(); for(InjectionPoint injectionPoint : beanInjectionPoints) { if(!injectionPoint.isTransient()) { @@ -82,6 +83,7 @@ public class CdiEjbBeanT extends BaseE || EntityManager.class.equals(injectionPoint.getAnnotated().getBaseType())) { continue; } + throw new WebBeansConfigurationException( Passivation capable beans must satisfy passivation capable dependencies. + Bean : + toString() + does not satisfy. Details about the Injection-point: +
svn commit: r1443480 - /tomee/tomee/trunk/tomee/tomee-catalina/src/main/java/org/apache/tomee/catalina/SimpleTomEETcpCluster.java
Author: rmannibucau Date: Thu Feb 7 13:57:30 2013 New Revision: 1443480 URL: http://svn.apache.org/viewvc?rev=1443480view=rev Log: TOMEE-609 cluster deployer needs a reference to tcp cluster Modified: tomee/tomee/trunk/tomee/tomee-catalina/src/main/java/org/apache/tomee/catalina/SimpleTomEETcpCluster.java Modified: tomee/tomee/trunk/tomee/tomee-catalina/src/main/java/org/apache/tomee/catalina/SimpleTomEETcpCluster.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/tomee/tomee-catalina/src/main/java/org/apache/tomee/catalina/SimpleTomEETcpCluster.java?rev=1443480r1=1443479r2=1443480view=diff == --- tomee/tomee/trunk/tomee/tomee-catalina/src/main/java/org/apache/tomee/catalina/SimpleTomEETcpCluster.java (original) +++ tomee/tomee/trunk/tomee/tomee-catalina/src/main/java/org/apache/tomee/catalina/SimpleTomEETcpCluster.java Thu Feb 7 13:57:30 2013 @@ -64,6 +64,9 @@ public class SimpleTomEETcpCluster exten for (ClusterListener clusterListener : currentListeners) { clusterListener.setCluster(this); // we don't care about TomEEClusterListener since it is stateless } +if (getClusterDeployer() != null) { +getClusterDeployer().setCluster(this); +} super.checkDefaults(); addClusterListener(TomEEClusterListener.INSTANCE); // since that's a singleton and all listeners have to be unique (contains()) we can always add it
[jira] [Commented] (TOMEE-609) Session replication is not working
[ https://issues.apache.org/jira/browse/TOMEE-609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573495#comment-13573495 ] Romain Manni-Bucau commented on TOMEE-609: -- hmm can you retry with next snapshot please? think a line was not commited, should be better now Session replication is not working -- Key: TOMEE-609 URL: https://issues.apache.org/jira/browse/TOMEE-609 Project: TomEE Issue Type: Bug Affects Versions: 1.5.0 Environment: Windows 7, Windows Server 2008, java version 1.6.0_21 Reporter: Dmitry Volkov Fix For: 1.5.1 Attachments: effective-web.xml, example.war Session is not replicated with standart Cluster configuration: Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster/ The application has distributable/ tag in web.xml, but it is absent in effective web.xml. (logEffectiveWebXml=true) Cluster members can find eachother, session is created, but there is no session backup on another member. I have checked it with manager application. Replication in the same application with same configuration deployed under tomcat 7.0.29 works as expected. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (TOMEE-609) Session replication is not working
[ https://issues.apache.org/jira/browse/TOMEE-609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573519#comment-13573519 ] Ihor Kolodyuk commented on TOMEE-609: - Dear Romain, it works for both cases now also with explicit declaration, I did a wrong check last time today, once again thank you very much, you are cool ;) Session replication is not working -- Key: TOMEE-609 URL: https://issues.apache.org/jira/browse/TOMEE-609 Project: TomEE Issue Type: Bug Affects Versions: 1.5.0 Environment: Windows 7, Windows Server 2008, java version 1.6.0_21 Reporter: Dmitry Volkov Fix For: 1.5.1 Attachments: effective-web.xml, example.war Session is not replicated with standart Cluster configuration: Cluster className=org.apache.catalina.ha.tcp.SimpleTcpCluster/ The application has distributable/ tag in web.xml, but it is absent in effective web.xml. (logEffectiveWebXml=true) Cluster members can find eachother, session is created, but there is no session backup on another member. I have checked it with manager application. Replication in the same application with same configuration deployed under tomcat 7.0.29 works as expected. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (TOMEE-764) ignoring webapps already extracted when removing default webapps with tomee maven plugin
[ https://issues.apache.org/jira/browse/TOMEE-764?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau updated TOMEE-764: - Issue Type: Bug (was: Dependency upgrade) ignoring webapps already extracted when removing default webapps with tomee maven plugin Key: TOMEE-764 URL: https://issues.apache.org/jira/browse/TOMEE-764 Project: TomEE Issue Type: Bug Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Created] (TOMEE-764) ignoring webapps already extracted when removing default webapps with tomee maven plugin
Romain Manni-Bucau created TOMEE-764: Summary: ignoring webapps already extracted when removing default webapps with tomee maven plugin Key: TOMEE-764 URL: https://issues.apache.org/jira/browse/TOMEE-764 Project: TomEE Issue Type: Dependency upgrade Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (TOMEE-764) ignoring webapps already extracted when removing default webapps with tomee maven plugin
[ https://issues.apache.org/jira/browse/TOMEE-764?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau resolved TOMEE-764. -- Resolution: Fixed ignoring webapps already extracted when removing default webapps with tomee maven plugin Key: TOMEE-764 URL: https://issues.apache.org/jira/browse/TOMEE-764 Project: TomEE Issue Type: Bug Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (TOMEE-763) tomee maven plugin context to define the context of current war without playing with finalName
[ https://issues.apache.org/jira/browse/TOMEE-763?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau resolved TOMEE-763. -- Resolution: Fixed tomee maven plugin context to define the context of current war without playing with finalName Key: TOMEE-763 URL: https://issues.apache.org/jira/browse/TOMEE-763 Project: TomEE Issue Type: New Feature Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1443501 - /tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java
Author: rmannibucau Date: Thu Feb 7 14:26:54 2013 New Revision: 1443501 URL: http://svn.apache.org/viewvc?rev=1443501view=rev Log: TOMEE-763 TOMEE-764 adding context option + ignoring webapps added by the user when removing default webapps Modified: tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java Modified: tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java?rev=1443501r1=1443500r2=1443501view=diff == --- tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java (original) +++ tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java Thu Feb 7 14:26:54 2013 @@ -140,6 +140,12 @@ public abstract class AbstractTomEEMojo protected File catalinaBase; /** + * rename the current artifact + */ +@Parameter +protected String context; + +/** * relative to tomee.base. */ @Parameter(defaultValue = webapps) @@ -227,12 +233,19 @@ public abstract class AbstractTomEEMojo tomeeVersion = 1 + version.substring(1, version.length()); } +final CollectionString existingWebapps; // added before using the plugin with maven dependency plugin or sthg like that +if (removeDefaultWebapps) { +existingWebapps = webappsAlreadyAdded(); +} else { +existingWebapps = Collections.emptyList(); +} + unzip(resolve(), catalinaBase); if (removeDefaultWebapps) { // do it first to let add other war -removeDefaultWebapps(removeTomeeWebapp); +removeDefaultWebapps(removeTomeeWebapp, existingWebapps); } copyLibs(libs, new File(catalinaBase, libDir), jar); -copyLibs(webapps, new File(catalinaBase, webappDir), war); // TODO: manage custom context ?context=foo +copyLibs(webapps, new File(catalinaBase, webappDir), war); copyLibs(apps, new File(catalinaBase, appDir), jar); overrideConf(config); overrideConf(lib); @@ -259,6 +272,20 @@ public abstract class AbstractTomEEMojo run(); } +private ListString webappsAlreadyAdded() { +final ListString list = new ArrayListString(); +final File webapps = new File(catalinaBase, webappDir); +if (webapps.exists() webapps.isDirectory()) { +final File[] files = webapps.listFiles(); +if (files != null) { +for (File f : files) { +list.add(f.getName()); +} +} +} +return list; +} + private String activateSimpleLog() { // adding SimpleTomEEFormatter to the classpath final String cp = InstallationEnrichers.addOneLineFormatter(catalinaBase); @@ -284,17 +311,19 @@ public abstract class AbstractTomEEMojo return null; } -private void removeDefaultWebapps(final boolean removeTomee) { +private void removeDefaultWebapps(final boolean removeTomee, final CollectionString providedWebapps) { final File webapps = new File(catalinaBase, webappDir); if (webapps.isDirectory()) { final File[] files = webapps.listFiles(); -if (null != files) for (File webapp : files) { -final String name = webapp.getName(); -if (webapp.isDirectory() (removeTomee || !name.equals(tomee))) { -try { -deleteDirectory(webapp); -} catch (IOException ignored) { -// no-op +if (null != files) { +for (File webapp : files) { +final String name = webapp.getName(); +if (webapp.isDirectory() !providedWebapps.contains(name) (removeTomee || !name.equals(tomee))) { +try { +deleteDirectory(webapp); +} catch (IOException ignored) { +// no-op +} } } } @@ -411,7 +440,7 @@ public abstract class AbstractTomEEMojo } final boolean war = war.equals(packaging); -final String name = warFile.getName(); +final String name = destinationName(); final File out; if (war) { out = new File(catalinaBase, webappDir + / + name); @@ -462,6 +491,16 @@ public abstract class AbstractTomEEMojo deployedFile = out; } +private String destinationName() { +if (context != null) { +if
[jira] [Updated] (TOMEE-763) tomee maven plugin context to define the context of current war without playing with finalName
[ https://issues.apache.org/jira/browse/TOMEE-763?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Romain Manni-Bucau updated TOMEE-763: - Issue Type: New Feature (was: Dependency upgrade) tomee maven plugin context to define the context of current war without playing with finalName Key: TOMEE-763 URL: https://issues.apache.org/jira/browse/TOMEE-763 Project: TomEE Issue Type: New Feature Reporter: Romain Manni-Bucau Assignee: Romain Manni-Bucau Fix For: 1.5.2 -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1443518 - /tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java
Author: rmannibucau Date: Thu Feb 7 14:53:08 2013 New Revision: 1443518 URL: http://svn.apache.org/viewvc?rev=1443518view=rev Log: deleting unpacked folder before starting tomee mvn plugin Modified: tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java Modified: tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java?rev=1443518r1=1443517r2=1443518view=diff == --- tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java (original) +++ tomee/tomee/trunk/maven/tomee-maven-plugin/src/main/java/org/apache/openejb/maven/plugin/AbstractTomEEMojo.java Thu Feb 7 14:53:08 2013 @@ -452,7 +452,7 @@ public abstract class AbstractTomEEMojo out = new File(parent, name); } delete(out); -if (out.exists() !out.isDirectory()) { +if (!out.isDirectory()) { final String dir = name.substring(0, name.lastIndexOf('.')); final File unpacked; if (war) {
[jira] [Updated] (OPENEJB-1997) warning/exception at server start about META-INF
[ https://issues.apache.org/jira/browse/OPENEJB-1997?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Lars Herschke updated OPENEJB-1997: --- Attachment: Deployer.ear warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Attachments: Deployer.ear Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (OPENEJB-1997) warning/exception at server start about META-INF
[ https://issues.apache.org/jira/browse/OPENEJB-1997?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573563#comment-13573563 ] Lars Herschke commented on OPENEJB-1997: I have attached a sample, now. I get no warning or exception if i hot deploy (with openejb deploy command) the app. The message appears in the logfile only at server start. My applications works fine ever, also after server start, without new deploy. warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Attachments: Deployer.ear Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1443537 - /tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java
Author: rmannibucau Date: Thu Feb 7 15:12:06 2013 New Revision: 1443537 URL: http://svn.apache.org/viewvc?rev=1443537view=rev Log: don't validate passivation for ejb which are not stateful - a lookup doesn't care Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java?rev=1443537r1=1443536r2=1443537view=diff == --- tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java (original) +++ tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/cdi/CdiEjbBean.java Thu Feb 7 15:12:06 2013 @@ -70,10 +70,14 @@ public class CdiEjbBeanT extends BaseE passivatingId = beanContext.getDeploymentID() + getReturnType().getName(); } -@Override // copied to be able to produce EM (should be fixed in OWB for next CDI spec) +@Override public void validatePassivationDependencies() { -// if(isPassivationCapable()) { - if(getWebBeansContext().getBeanManagerImpl().isPassivatingScope(getScope())) { // not @Dependent otherwise we either can't inject EJB in serializable beans or the opposite +if (!BeanType.STATEFUL.equals(beanContext.getComponentType())) { // always serializable since we redo a lookup +return; +} + +final Class? extends Annotation scope = getScope(); + if(getWebBeansContext().getBeanManagerImpl().isPassivatingScope(scope)) { // not @Dependent otherwise we either can't inject EJB in serializable beans or the opposite final SetInjectionPoint beanInjectionPoints = getInjectionPoints(); for(InjectionPoint injectionPoint : beanInjectionPoints) { if(!injectionPoint.isTransient()) { @@ -107,12 +111,12 @@ public class CdiEjbBeanT extends BaseE for (InterceptorData interceptorData : interceptorStack) { if (interceptorData.isDefinedWithWebBeansInterceptor()) { WebBeansInterceptor? interceptor = (WebBeansInterceptor?) interceptorData.getWebBeansInterceptor(); -if (!interceptor.isPassivationCapable()) { -throw new WebBeansConfigurationException(MessageFormat.format( - WebBeansLoggerFacade.getTokenString(OWBLogConst.EXCEPT_0016), toString())); -} else { -interceptor.validatePassivationDependencies(); -} +if (!interceptor.isPassivationCapable()) { +throw new WebBeansConfigurationException(MessageFormat.format( + WebBeansLoggerFacade.getTokenString(OWBLogConst.EXCEPT_0016), toString())); +} else { +interceptor.validatePassivationDependencies(); +} } else { if (interceptorData.isDefinedInInterceptorClass()) { Class? interceptorClass = interceptorData.getInterceptorClass();
svn commit: r1443555 - in /tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources: openejb openejb.bat
Author: rmannibucau Date: Thu Feb 7 15:31:02 2013 New Revision: 1443555 URL: http://svn.apache.org/viewvc?rev=1443555view=rev Log: javaee-api is needed to start correctly openejb Modified: tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb.bat Modified: tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb?rev=1443555r1=1443554r2=1443555view=diff == --- tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb (original) +++ tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb Thu Feb 7 15:31:02 2013 @@ -76,10 +76,10 @@ fi OPTIONS=-Dopenejb.home=$OPENEJB_HOME -OPENEJB_CORE_JAR=$OPENEJB_HOME/lib/openejb-core-${version}.jar +OPENEJB_CORE_JAR=$OPENEJB_HOME/lib/openejb-core-${version}.jar:$OPENEJB_HOME/lib/$(ls $OPENEJB_HOME/lib | grep javaee-api) OPENEJB_JAVAAGENT_JAR=$OPENEJB_HOME/lib/openejb-javaagent-${version}.jar ## Uncomment for easy debug setup # OPENEJB_OPTS=-Xdebug -Xnoagent -Djava.compiler=NONE -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005 -java $OPENEJB_OPTS -Djava.util.logging.config.file=$OPENEJB_HOME/conf/logging.properties -javaagent:$OPENEJB_JAVAAGENT_JAR -jar $OPENEJB_CORE_JAR $@ +java $OPENEJB_OPTS -Djava.util.logging.config.file=$OPENEJB_HOME/conf/logging.properties -javaagent:$OPENEJB_JAVAAGENT_JAR -cp $OPENEJB_CORE_JAR org.apache.openejb.cli.Bootstrap $@ Modified: tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb.bat URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb.bat?rev=1443555r1=1443554r2=1443555view=diff == --- tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb.bat (original) +++ tomee/tomee/trunk/assembly/openejb-standalone/src/main/resources/openejb.bat Thu Feb 7 15:31:02 2013 @@ -44,7 +44,7 @@ set OPENEJB_HOME=%CD% REM echo OPENEJB_HOME is: %OPENEJB_HOME% -set OPENEJB_CORE_JAR=%OPENEJB_HOME%\lib\openejb-core-*.jar +set OPENEJB_CORE_JAR=%OPENEJB_HOME%\lib\openejb-core-*.jar;$OPENEJB_HOME/lib/javaee-api-*.jar set OPENEJB_JAVAAGENT_JAR=%OPENEJB_HOME%\lib\openejb-javaagent-*.jar for %%a in (%OPENEJB_CORE_JAR%) do ( @@ -69,7 +69,7 @@ set OPTIONS=-Dopenejb.home=%OPENEJB_HOME REM echo %OPENEJB_OPTS% -javaagent:%OPENEJB_JAVAAGENT_JAR% -jar %OPENEJB_CORE_JAR% %* -java %OPENEJB_OPTS% -Djava.util.logging.config.file=%OPENEJB_HOME%/conf/logging.properties -javaagent:%OPENEJB_JAVAAGENT_JAR% -jar %OPENEJB_CORE_JAR% %* +java %OPENEJB_OPTS% -Djava.util.logging.config.file=%OPENEJB_HOME%/conf/logging.properties -javaagent:%OPENEJB_JAVAAGENT_JAR% -cp %OPENEJB_CORE_JAR% org.apache.openejb.cli.Bootstrap %* :EOF ENDLOCAL
[jira] [Commented] (OPENEJB-1997) warning/exception at server start about META-INF
[ https://issues.apache.org/jira/browse/OPENEJB-1997?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573593#comment-13573593 ] Romain Manni-Bucau commented on OPENEJB-1997: - can you try the snapshot (https://repository.apache.org/content/groups/public/org/apache/openejb/openejb-standalone/4.5.2-SNAPSHOT/), maybe i'm doing something wrong but i don't get it warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Attachments: Deployer.ear Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (OPENEJB-1997) warning/exception at server start about META-INF
[ https://issues.apache.org/jira/browse/OPENEJB-1997?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13573627#comment-13573627 ] Lars Herschke commented on OPENEJB-1997: I have tried openejb-standalone-4.5.2-20130207.040712-64.tar.gz and i get still the exception. I don't changed any file (also no config-file) on the snapshot. Only the unpacked Deployer.ear ist under the apps/Deployer-directory warning/exception at server start about META-INF Key: OPENEJB-1997 URL: https://issues.apache.org/jira/browse/OPENEJB-1997 Project: OpenEJB Issue Type: Bug Components: deployment, server Affects Versions: 4.5.1 Environment: FreeBSD 6.4-STABLE i386 Reporter: Lars Herschke Priority: Minor Attachments: Deployer.ear Jar not loaded. /usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF. Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF org.apache.openejb.config.UnknownModuleTypeException: Unable to determine module type for jar: file:/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF/: Unknown module type: url=/usr/local/apache-openejb-4.5.1/apps/Deployer/META-INF Such a warning is showing on all deployed apps during server start. The directory structure of the Deployer-dir is: Deployer |ejb-jar-ic.jar |META-INF |MANIFEST.MF |application.xml This issue is since version 4.5.1, till 4.5.0 such exception is not thrown. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira
svn commit: r1443632 - in /tomee/tomee/trunk/server: openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/ openejb-rest/src/main/java/org/apache/openejb/server/rest/
Author: rmannibucau Date: Thu Feb 7 17:59:53 2013 New Revision: 1443632 URL: http://svn.apache.org/r1443632 Log: propagating the contextRoot for all rest deployment Modified: tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/CxfRsHttpListener.java tomee/tomee/trunk/server/openejb-rest/src/main/java/org/apache/openejb/server/rest/RESTService.java tomee/tomee/trunk/server/openejb-rest/src/main/java/org/apache/openejb/server/rest/RsHttpListener.java Modified: tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/CxfRsHttpListener.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/CxfRsHttpListener.java?rev=1443632r1=1443631r2=1443632view=diff == --- tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/CxfRsHttpListener.java (original) +++ tomee/tomee/trunk/server/openejb-cxf-rs/src/main/java/org/apache/openejb/server/cxf/rs/CxfRsHttpListener.java Thu Feb 7 17:59:53 2013 @@ -116,7 +116,14 @@ public class CxfRsHttpListener implement if (httpRequest instanceof HttpRequestImpl) { ((HttpRequestImpl) httpRequest).initPathFromContext(context); } -httpRequest.setAttribute(org.apache.cxf.transport.endpoint.address, BaseUrlHelper.getBaseURL(httpRequest) + /); + + +String baseURL = BaseUrlHelper.getBaseURL(httpRequest); +if (!baseURL.endsWith(/)) { +baseURL += /; +} + +httpRequest.setAttribute(org.apache.cxf.transport.endpoint.address, baseURL); // delegate invocation destination.invoke(null, httpRequest.getServletContext(), new HttpServletRequestWrapper(httpRequest) { @@ -184,31 +191,38 @@ public class CxfRsHttpListener implement } @Override -public void deploySingleton(String fullContext, Object o, Application appInstance, +public void deploySingleton(String contextRoot, String fullContext, Object o, Application appInstance, CollectionObject additionalProviders, ServiceConfiguration configuration) { -deploy(o.getClass(), fullContext, new SingletonResourceProvider(o), o, appInstance, null, additionalProviders, configuration); +deploy(contextRoot, o.getClass(), fullContext, new SingletonResourceProvider(o), o, appInstance, null, additionalProviders, configuration); } @Override -public void deployPojo(String fullContext, Class? loadedClazz, Application app, CollectionInjection injections, +public void deployPojo(String contextRoot, String fullContext, Class? loadedClazz, Application app, CollectionInjection injections, Context context, WebBeansContext owbCtx, CollectionObject additionalProviders, ServiceConfiguration configuration) { -deploy(loadedClazz, fullContext, new OpenEJBPerRequestPojoResourceProvider(loadedClazz, injections, context, owbCtx), +deploy(contextRoot, loadedClazz, fullContext, new OpenEJBPerRequestPojoResourceProvider(loadedClazz, injections, context, owbCtx), null, app, null, additionalProviders, configuration); } @Override -public void deployEJB(String fullContext, BeanContext beanContext, CollectionObject additionalProviders, ServiceConfiguration configuration) { +public void deployEJB(String contextRoot, String fullContext, BeanContext beanContext, CollectionObject additionalProviders, ServiceConfiguration configuration) { final Object proxy = ProxyEJB.subclassProxy(beanContext); -deploy(beanContext.getBeanClass(), fullContext, new NoopResourceProvider(beanContext.getBeanClass(), proxy), +deploy(contextRoot, beanContext.getBeanClass(), fullContext, new NoopResourceProvider(beanContext.getBeanClass(), proxy), proxy, null, new OpenEJBEJBInvoker(Collections.singleton(beanContext)), additionalProviders, configuration); } -private void deploy(Class? clazz, String address, ResourceProvider rp, Object serviceBean, Application app, Invoker invoker, -CollectionObject additionalProviders, ServiceConfiguration configuration) { +private void deploy(String contextRoot, Class? clazz, String address, ResourceProvider rp, Object serviceBean, +Application app, Invoker invoker, CollectionObject additionalProviders, ServiceConfiguration configuration) { final JAXRSServerFactoryBean factory = newFactory(address); configureFactory(additionalProviders, configuration, factory); factory.setResourceClasses(clazz); +context = contextRoot; +if (context == null) { +context = ; +} +if (!context.startsWith(/)) { +context = / + context; +}
svn commit: r1443814 - /tomee/tomee/trunk/examples/simple-cdi-interceptor/src/main/java/org/superbiz/cdi/bookshow/interceptors/LoggingInterceptor.java
Author: rmannibucau Date: Fri Feb 8 01:22:17 2013 New Revision: 1443814 URL: http://svn.apache.org/r1443814 Log: stateful is serializable so interceptor should be too Modified: tomee/tomee/trunk/examples/simple-cdi-interceptor/src/main/java/org/superbiz/cdi/bookshow/interceptors/LoggingInterceptor.java Modified: tomee/tomee/trunk/examples/simple-cdi-interceptor/src/main/java/org/superbiz/cdi/bookshow/interceptors/LoggingInterceptor.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/examples/simple-cdi-interceptor/src/main/java/org/superbiz/cdi/bookshow/interceptors/LoggingInterceptor.java?rev=1443814r1=1443813r2=1443814view=diff == --- tomee/tomee/trunk/examples/simple-cdi-interceptor/src/main/java/org/superbiz/cdi/bookshow/interceptors/LoggingInterceptor.java (original) +++ tomee/tomee/trunk/examples/simple-cdi-interceptor/src/main/java/org/superbiz/cdi/bookshow/interceptors/LoggingInterceptor.java Fri Feb 8 01:22:17 2013 @@ -37,10 +37,11 @@ import org.superbiz.cdi.bookshow.interce import javax.interceptor.AroundInvoke; import javax.interceptor.Interceptor; import javax.interceptor.InvocationContext; +import java.io.Serializable; @Interceptor @Log -public class LoggingInterceptor { +public class LoggingInterceptor implements Serializable { private static final long serialVersionUID = 8139854519874743530L; @AroundInvoke
svn commit: r1443819 - /tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/core/managed/ManagedContainer.java
Author: rmannibucau Date: Fri Feb 8 01:42:11 2013 New Revision: 1443819 URL: http://svn.apache.org/r1443819 Log: Removable interface handling for ManagedContainer Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/core/managed/ManagedContainer.java Modified: tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/core/managed/ManagedContainer.java URL: http://svn.apache.org/viewvc/tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/core/managed/ManagedContainer.java?rev=1443819r1=1443818r2=1443819view=diff == --- tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/core/managed/ManagedContainer.java (original) +++ tomee/tomee/trunk/container/openejb-core/src/main/java/org/apache/openejb/core/managed/ManagedContainer.java Fri Feb 8 01:42:11 2013 @@ -116,6 +116,12 @@ public class ManagedContainer implements private MapMethod, MethodType getLifecycleMethodsOfInterface(final BeanContext beanContext) { final MapMethod, MethodType methods = new HashMapMethod, MethodType(); +try { + methods.put(BeanContext.Removable.class.getDeclaredMethod($$remove), MethodType.REMOVE); +} catch (NoSuchMethodException e) { +throw new IllegalStateException(Internal code change: BeanContext.Removable.$$remove() method was deleted, e); +} + final ListMethod removeMethods = beanContext.getRemoveMethods(); for (final Method removeMethod : removeMethods) { methods.put(removeMethod, MethodType.REMOVE); @@ -457,7 +463,10 @@ public class ManagedContainer implements final ThreadContext oldCallContext = ThreadContext.enter(callContext); try { // Security check -checkAuthorization(callMethod, interfaceType); +boolean internalRemove = BeanContext.Removable.class == callMethod.getDeclaringClass(); +if (!internalRemove) { +checkAuthorization(callMethod, interfaceType); +} // If a bean managed transaction is active, the bean can not be removed if (interfaceType.isComponent()) { @@ -499,34 +508,36 @@ public class ManagedContainer implements } } -// Register the entity managers -registerEntityManagers(instance, callContext); - -// Register for synchronization callbacks -registerSessionSynchronization(instance, callContext); - -// Setup for remove invocation -callContext.setCurrentOperation(Operation.REMOVE); -callContext.setCurrentAllowedStates(null); -callContext.setInvokedInterface(callInterface); -runMethod = beanContext.getMatchingBeanMethod(callMethod); -callContext.set(Method.class, runMethod); - -// Do not pass arguments on home.remove(remote) calls -final Class? declaringClass = callMethod.getDeclaringClass(); -if (declaringClass.equals(EJBHome.class) || declaringClass.equals(EJBLocalHome.class)) { -args = new Object[]{}; -} +if (!internalRemove) { +// Register the entity managers +registerEntityManagers(instance, callContext); + +// Register for synchronization callbacks +registerSessionSynchronization(instance, callContext); + +// Setup for remove invocation +callContext.setCurrentOperation(Operation.REMOVE); +callContext.setCurrentAllowedStates(null); +callContext.setInvokedInterface(callInterface); +runMethod = beanContext.getMatchingBeanMethod(callMethod); +callContext.set(Method.class, runMethod); + +// Do not pass arguments on home.remove(remote) calls +final Class? declaringClass = callMethod.getDeclaringClass(); +if (declaringClass.equals(EJBHome.class) || declaringClass.equals(EJBLocalHome.class)) { +args = new Object[]{}; +} -// Initialize interceptor stack -final ListInterceptorData interceptors = beanContext.getMethodInterceptors(runMethod); -final InterceptorStack interceptorStack = new InterceptorStack(instance.bean, runMethod, Operation.REMOVE, interceptors, instance.interceptors); +// Initialize interceptor stack +final ListInterceptorData interceptors = beanContext.getMethodInterceptors(runMethod); +final InterceptorStack interceptorStack = new InterceptorStack(instance.bean, runMethod, Operation.REMOVE,