[jira] [Commented] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13759398#comment-13759398 ] Leonardo Uribe commented on OWB-895: While I was preparing the example I saw the exception is not present anymore. It seems there was a class conflict in the example I was trying to run, but I can confirm the latest snapshot looks good. You can close this issue as fixed or duplicate, since the original issue from this report was fixed in some point between OWB 1.2.0 and 1.2.1-SNAPSHOT. Thanks for the help. BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13757073#comment-13757073 ] Leonardo Uribe commented on OWB-895: I have tried with the latest snapshot and the exception is still present (apache-tomee-1.6.0-20130903.041125-168-webprofile.zip). I'll provide an example soon. BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13757088#comment-13757088 ] Romain Manni-Bucau commented on OWB-895: Note: container beans can be configured through http://svn.apache.org/repos/asf/tomee/tomee/trunk/container/openejb-core/src/main/resources/container-cdi-classes.properties (just replace this file in a higher classloader than common to override it) i'm waiting your sample to go ahead BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13749874#comment-13749874 ] Romain Manni-Bucau commented on OWB-895: could you try on trunk (tomee)? BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13749677#comment-13749677 ] Romain Manni-Bucau commented on OWB-895: @Leonardo: can you list classes we would need to scan? BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13749360#comment-13749360 ] Romain Manni-Bucau commented on OWB-895: Hi Tomee filters jars and classes by app classloader. In all cases having a simple sample would help to dig into it (i guess you have it ;) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13749461#comment-13749461 ] Romain Manni-Bucau commented on OWB-895: @Mark: scan.xml will not work here + we will not scan myfaces, bval, openjpa but integrate them for perf + avoid issues when using mojarra or hibernate* BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13748788#comment-13748788 ] Mark Struberg commented on OWB-895: --- I guess it's because all libs in tomee folder/lib are excluded by default to speed up scanning. For EE7 we would need to scan a few jars in those lib folders, e.g. bval and openjpa as well. Tomee knows a mechanism via a scan.xml to speed up the scanning process which we could use. BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13748870#comment-13748870 ] Leonardo Uribe commented on OWB-895: Hi I tried the latest snapshot (apache-tomee-1.6.0-20130823.041201-155-webprofile.zip) and the problem was fixed at some point between OWB 1.2.0 and 1.2.1-SNAPSHOT. But I notice another different problem related to the producers. Suppose this producer method: public class SimpleFlow implements Serializable { @Produces @FlowDefinition public Flow defineFlow(@FlowBuilderParameter FlowBuilder flowBuilder) { Note the base class is not defined as bean. If the code is deployed, it works well with OWB and Weld but with Tomee configuration it throws this exception: SEVERE: CDI Beans module deployment failed java.lang.NullPointerException at sun.reflect.annotation.AnnotationInvocationHandler.memberValueEquals(AnnotationInvocationHandler.java:233) at sun.reflect.annotation.AnnotationInvocationHandler.equalsImpl(AnnotationInvocationHandler.java:204) at sun.reflect.annotation.AnnotationInvocationHandler.invoke(AnnotationInvocationHandler.java:59) at com.sun.proxy.$Proxy37.equals(Unknown Source) at org.apache.webbeans.util.AnnotationUtil.isDeclaringClass(AnnotationUtil.java:68) at org.apache.webbeans.util.AnnotationUtil.getDeclaringClass(AnnotationUtil.java:85) at org.apache.webbeans.component.creation.BeanAttributesBuilder.defineScope(BeanAttributesBuilder.java:255) at org.apache.webbeans.component.creation.BeanAttributesBuilder$AnnotatedTypeBeanAttributesBuilder.defineScope(BeanAttributesBuilder.java:505) at org.apache.webbeans.component.creation.BeanAttributesBuilder.build(BeanAttributesBuilder.java:106) at org.apache.webbeans.config.BeansDeployer.defineManagedBean(BeansDeployer.java:923) at org.apache.webbeans.config.BeansDeployer.deploySingleAnnotatedType(BeansDeployer.java:637) at org.apache.webbeans.config.BeansDeployer.deployFromClassPath(BeansDeployer.java:567) at org.apache.webbeans.config.BeansDeployer.deploy(BeansDeployer.java:189) at org.apache.openejb.cdi.OpenEJBLifecycle.startApplication(OpenEJBLifecycle.java:187) at org.apache.openejb.cdi.ThreadSingletonServiceImpl.initialize(ThreadSingletonServiceImpl.java:162) at org.apache.openejb.cdi.CdiBuilder.build(CdiBuilder.java:43) at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:799) at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:613) at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1122) at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:985) at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:127) 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.StandardContext.startInternal(StandardContext.java:5322) at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150) at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901) at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877) at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:633) at org.apache.catalina.startup.HostConfig.deployDirectory(HostConfig.java:1113) at org.apache.catalina.startup.HostConfig$DeployDirectory.run(HostConfig.java:1671) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:334) at java.util.concurrent.FutureTask.run(FutureTask.java:166) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) at java.lang.Thread.run(Thread.java:724) org.apache.openejb.OpenEJBException: Creating application failed: at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:897) at org.apache.openejb.assembler.classic.Assembler.createApplication(Assembler.java:613) at org.apache.tomee.catalina.TomcatWebAppBuilder.startInternal(TomcatWebAppBuilder.java:1122) at org.apache.tomee.catalina.TomcatWebAppBuilder.configureStart(TomcatWebAppBuilder.java:985) at org.apache.tomee.catalina.GlobalListenerSupport.lifecycleEvent(GlobalListenerSupport.java:127) at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:119) at
[jira] [Commented] (OWB-895) BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder
[ https://issues.apache.org/jira/browse/OWB-895?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanelfocusedCommentId=13748297#comment-13748297 ] Romain Manni-Bucau commented on OWB-895: Hi Maybe give it a try on 1.6.0-SNAPSHOT, we had issues on codi before due to our default exclusions BeforeBeanDiscovery.addAnnotatedType() calls does not work as expected when owb jars are deployed outside WEB-INF/lib folder Key: OWB-895 URL: https://issues.apache.org/jira/browse/OWB-895 Project: OpenWebBeans Issue Type: Bug Components: Context and Scopes, Injection and Lookup, Java EE Integration Affects Versions: 1.1.8 Environment: Apache Tomee 1.5.2, OpenWebBeans 1.1.8 Reporter: Leonardo Uribe I have been working on the CDI extension points of MyFaces Core 2.2.x, specially the part related to @ViewScoped and @FlowScoped annotations. The solution proposed and committed on the latest snapshot works with weld and openwebbeans. But on the way, I have found a problem when I tried to deploy a demo application in Tomee 1.5.2 MyFaces jars has internally some beans that needs to be registered in CDI: - org.apache.myfaces.flow.cdi.FlowBuilderFactoryBean (deals with @FlowBuilderParameter and @FlowDefinition) - org.apache.myfaces.flow.cdi.FlowScopeBeanHolder (session scope bean that store flow scope) - org.apache.myfaces.cdi.view.ViewScopeBeanHolder (session scope bean that store view scope) And in the classes implementing Extension you can find some code like this to register the beans: void beforeBeanDiscovery( @Observes final BeforeBeanDiscovery event, BeanManager beanManager) { // Register FlowBuilderFactoryBean as a bean with CDI annotations, so the system // can take it into account, and use it later when necessary. AnnotatedType flowDiscoveryHelper = beanManager.createAnnotatedType(FlowBuilderFactoryBean.class); event.addAnnotatedType(flowDiscoveryHelper); } It works well as long as owb jars are located in WEB-INF/lib folder, but in Tomee, MyFaces and OWB jars are located in tomee folder/lib . In theory the code should work but it doesn't. The effect is the application fails because these beans are not registered on CDI environment. Suggestions are welcome. -- 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