hi gerald, @codi + seam yes - that's possible. it depends on what you are using from both. e.g. in case of the jsf-module of codi + seam-faces you have to veto one of the producers for the FacesContext.
@ "No CreationalContext registered for EL evaluation, it is likely that the the expression factory has not been wrapped by the CDI BeanManager, which must be done to use the ELResolver from CDI": ... sounds like an as7 issue. it occurs during the rendering process (see e.g. UIComponentBase#encodeBegin) -> as7 has to ensure that all parts of cdi and jsf are up and running. @enabling injection via @Advanced: the only known (and already fixed) issue is [1]. just fyi (since you wrote "JSR-303 cross-field validation"). annotations like @DateIs were introduced before the bv-spec. was released and don't use the bv-api at all (that's the reason why they are in a different validation module). you would need e.g. [2] to use the bv-api with a thin layer to allow bv based cross-field validation. regards, gerhard [1] https://issues.apache.org/jira/browse/EXTCDI-302 [2] http://os890.blogspot.co.at/2010/06/multi-field-form-validation-with-jsr.html http://www.irian.at Your JSF/JavaEE powerhouse - JavaEE Consulting, Development and Courses in English and German Professional Support for Apache MyFaces 2012/12/4 Gerald Turner <gtur...@unzane.com> > Hello, I'm in the process of converting a JSF2/CDI application from > Seam3 to MyFaces ExtCDI/CODI. The application had been using MyFaces > ExtVal-BV so that JSR-303 cross-field validation would work in the > front-end. Simply replacing Seam3 with CODI evoked the following > stacktrace during the first page view (during MyFaces EXT* lazy init), > and ExtVal-BV doesn't seem to be working entirely (annotations like > @DateIs work, but my ConstraintValidators aren't being executed). > Things actually get worse than that, some injection points no longer > work, particularly on an abstract superclass - but I figure I should > solve this warning before exploring that issue. Also injection in > FacesConverter and ConstraintValidators (when triggered by JPA) don't > work even after annotating with @Advanced - again, probably a secondary > effect. Also yet another tangent - I've heard that CODI and Seam3 can > be deployed together, but under JBoss 7.1.1.Final the app doesn't deploy > due to Weld errors with ambiguous producers - I haven't found any > documentation that describes any Veto-esque configuration. > > This looks exactly like JIRA issue EXTVAL-130, only I'm using JBoss > 7.1.1.Final instead of Glassfish, but they both share Weld, and I am > using ExtVal 2.0.6, which is the fixed version. > > Relevant parts of my pom.xml: > > <!-- CDI & MyFaces ExtCDI/CODI --> > <dependency> > <groupId>javax.enterprise</groupId> > <artifactId>cdi-api</artifactId> > <version>1.0-SP4</version> > <scope>provided</scope> > </dependency> > <dependency> > <groupId>org.apache.myfaces.extensions.cdi.bundles</groupId> > <artifactId>myfaces-extcdi-bundle-jsf20</artifactId> > <version>1.0.5</version> > </dependency> > > <!-- MyFaces ExtVal --> > <dependency> > > <groupId>org.apache.myfaces.extensions.validator.validation-modules</groupId> > <artifactId>myfaces-extval-property-validation</artifactId> > <version>2.0.6</version> > <exclusions> > <exclusion> > <groupId>javax.persistence</groupId> > <artifactId>persistence-api</artifactId> > </exclusion> > </exclusions> > </dependency> > <dependency> > > <groupId>org.apache.myfaces.extensions.validator.validation-modules</groupId> > <artifactId>myfaces-extval-bean-validation</artifactId> > <version>2.0.6</version> > <exclusions> > <exclusion> > <groupId>javax.validation</groupId> > <artifactId>validation-api</artifactId> > </exclusion> > </exclusions> > </dependency> > > Some bits of the CODI startup version output (need to see the booleans > too?): > > 10:56:32,600 INFO > [org.apache.myfaces.extensions.cdi.jsf2.impl.Jsf2ModuleStartupObserver] > (http--0.0.0.0-8080-1) [Started] MyFaces CODI JSF-Module v1.0.5 for JSF 2.0 > Used JSF implementation: Mojarra vnull > > 10:56:32,611 INFO > [org.apache.myfaces.extensions.cdi.jpa.impl.JpaModuleStartupObserver] > (http--0.0.0.0-8080-1) [Started] MyFaces CODI JPA-Module v1.0.5 > > 10:56:32,620 INFO > [org.apache.myfaces.extensions.cdi.core.impl.CoreStartupObserver] > (http--0.0.0.0-8080-1) [Started] MyFaces CODI (Extensions CDI) Core v1.0.5 > Used CDI implementation: Weld v2012-02-10 15:31 > > The stacktrace: > > 10:56:33,838 WARNING > [org.apache.myfaces.extensions.validator.beanval.ValidatorFactoryProxy] > (http--0.0.0.0-8080-1) failed to lookup a bean with the name > contextAwareValidatorFactory: java.lang.IllegalStateException: No > CreationalContext registered for EL evaluation, it is likely that the the > expression factory has not been wrapped by the CDI BeanManager, which must > be done to use the ELResolver from CDI > at > org.jboss.weld.el.AbstractWeldELResolver.getELCreationalContext(AbstractWeldELResolver.java:148) > [weld-core-1.1.5.AS71.Final.jar:2012-02-10 15:31] > at > org.jboss.weld.el.AbstractWeldELResolver.lookup(AbstractWeldELResolver.java:123) > [weld-core-1.1.5.AS71.Final.jar:2012-02-10 15:31] > at > org.jboss.weld.el.AbstractWeldELResolver.getValue(AbstractWeldELResolver.java:96) > [weld-core-1.1.5.AS71.Final.jar:2012-02-10 15:31] > at > org.jboss.as.weld.webtier.jsf.ForwardingELResolver.getValue(ForwardingELResolver.java:46) > [jboss-as-weld-7.1.1.Final.jar:7.1.1.Final] > at javax.el.CompositeELResolver.getValue(CompositeELResolver.java:175) > [jboss-el-api_2.2_spec-1.0.0.Final.jar:1.0.0.Final] > at > com.sun.faces.el.DemuxCompositeELResolver._getValue(DemuxCompositeELResolver.java:176) > [jsf-impl-2.1.7-jbossorg-2.jar:] > at > com.sun.faces.el.DemuxCompositeELResolver.getValue(DemuxCompositeELResolver.java:203) > [jsf-impl-2.1.7-jbossorg-2.jar:] > at > org.apache.myfaces.extensions.validator.core.el.DefaultELHelper.getBean(DefaultELHelper.java:79) > [myfaces-extval-core-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.beanval.ValidatorFactoryProxy.getValidatorFactory(ValidatorFactoryProxy.java:58) > [myfaces-extval-bean-validation-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.beanval.ValidatorFactoryProxy.getValidator(ValidatorFactoryProxy.java:86) > [myfaces-extval-bean-validation-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.beanval.util.BeanValidationUtils.getElementDescriptor(BeanValidationUtils.java:108) > [myfaces-extval-bean-validation-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.beanval.BeanValidationModuleValidationInterceptorInternals.initComponentWithPropertyDetails(BeanValidationModuleValidationInterceptorInternals.java:104) > [myfaces-extval-bean-validation-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.beanval.BeanValidationModuleValidationInterceptor.initComponentWithPropertyDetails(BeanValidationModuleValidationInterceptor.java:70) > [myfaces-extval-bean-validation-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.beanval.BeanValidationModuleValidationInterceptor.initComponent(BeanValidationModuleValidationInterceptor.java:60) > [myfaces-extval-bean-validation-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.core.interceptor.AbstractValidationInterceptor.beforeEncodeBegin(AbstractValidationInterceptor.java:112) > [myfaces-extval-core-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.core.renderkit.ExtValRendererWrapper.encodeBegin(ExtValRendererWrapper.java:183) > [myfaces-extval-core-2.0.6.jar:2.0.6] > at > javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:820) > [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final] > at > com.sun.faces.renderkit.html_basic.HtmlBasicRenderer.encodeRecursive(HtmlBasicRenderer.java:302) > [jsf-impl-2.1.7-jbossorg-2.jar:] > at > com.sun.faces.renderkit.html_basic.GridRenderer.renderRow(GridRenderer.java:185) > [jsf-impl-2.1.7-jbossorg-2.jar:] > at > com.sun.faces.renderkit.html_basic.GridRenderer.encodeChildren(GridRenderer.java:129) > [jsf-impl-2.1.7-jbossorg-2.jar:] > at > org.apache.myfaces.extensions.validator.core.renderkit.ExtValLazyRendererProxy.encodeChildren(ExtValLazyRendererProxy.java:70) > [myfaces-extval-core-2.0.6.jar:2.0.6] > at > org.apache.myfaces.extensions.validator.core.renderkit.ExtValRendererWrapper.encodeChildren(ExtValRendererWrapper.java:286) > [myfaces-extval-core-2.0.6.jar:2.0.6] > at > javax.faces.component.UIComponentBase.encodeChildren(UIComponentBase.java:845) > [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final] > at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1779) > [jboss-jsf-api_2.1_spec-2.0.1.Final.jar:2.0.1.Final] > at javax.faces.rinal.jar:] > at org.jboss.as.jpa.interceptor.WebNonTxEmCl > > -- > Gerald Turner Email: gtur...@unzane.com JID: gtur...@unzane.com > GPG: 0xFA8CD6D5 21D9 B2E8 7FE7 F19E 5F7D 4D0C 3FA0 810F FA8C D6D5 >