2 Replies Latest reply on Jun 5, 2006 2:47 PM by Jonn Beames

    PropertyNotFoundException EL identifier resovling with JSF 1

    Jonn Beames Newbie

      Greetings Seam community,

      I've been working on a JSF+EJB3 project for a while... just started to integrate Seam this week; very cool stuff; very excited about the JSF+EJB3 problems it solves! I am in the process of replacing standard JSF managed beans with Seam components. Point being: I'm new to Seam, and I've got existing paterns to work around, so please be patient with my ignorance.

      I'm using JSF 1.2 RI; have been using a nightly build of 1.2_01 from 5-5-06 retrieved from the java.net maven repository:
      https://maven-repository.dev.java.net/repository/javax.faces/jars/

      This version is very similar to the "stable version" that is in EE5 SDK/App Server 9 PE releases and works with seam (in the few paces I've put it through in a 1/2 day of work). But this version has a duplicate attribute bug (more details see: http://forum.java.sun.com/thread.jspa?threadID=740189&tstart=15)

      I've grabbed the JSF 1.2 nightly from 6/4/06 which does not exhibit the duplicate attribute bug, but does appear to have broken Seam variable resolving. I get the following exception:

      2006-06-04 11:21:02,935 DEBUG [Lifecycle] >>> Begin web request
      2006-06-04 11:21:03,342 DEBUG [Component] instantiating Seam component: org.jboss.seam.core.manager
      2006-06-04 11:21:03,342 DEBUG [Manager] No stored conversation
      2006-06-04 11:21:03,342 DEBUG [Contexts] found in application context: org.jboss.seam.core.init
      2006-06-04 11:21:03,342 DEBUG [AbstractSeamPhaseListener] After restoring conversation context: ConversationContext(3)
      2006-06-04 11:21:03,342 DEBUG [SeamVariableResolver] resolving name: registrar
      2006-06-04 11:21:03,342 DEBUG [Component] instantiating Seam component: registrar
      2006-06-04 11:21:03,342 DEBUG [Naming] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory, java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
      2006-06-04 11:21:03,342 DEBUG [SeamVariableResolver] resolved name to seam component
      2006-06-04 11:21:03,357 ERROR [STDERR] Jun 4, 2006 11:21:03 AM com.sun.faces.lifecycle.ProcessValidationsPhase execute
      WARNING: /signin_beta.xhtml @29,85 value="#{registrar.betaInvite}": Target Unreachable, identifier 'registrar' resolved to null
      javax.el.PropertyNotFoundException: /signin_beta.xhtml @29,85 value="#{registrar.betaInvite}": Target Unreachable, identifier 'registrar' resolved to null
       at com.sun.facelets.el.TagValueExpression.getType(TagValueExpression.java:62)
       at com.sun.faces.renderkit.html_basic.HtmlBasicInputRenderer.getConvertedValue(HtmlBasicInputRenderer.java:129)
       at javax.faces.component.UIInput.getConvertedValue(UIInput.java:943)
       at javax.faces.component.UIInput.validate(UIInput.java:868)
       at javax.faces.component.UIInput.executeValidate(UIInput.java:1078)
       at javax.faces.component.UIInput.processValidators(UIInput.java:670)
       at javax.faces.component.UIForm.processValidators(UIForm.java:229)
       at javax.faces.component.UIComponentBase.processValidators(UIComponentBase.java:1039)
       at javax.faces.component.UIViewRoot.processValidators(UIViewRoot.java:693)
       at com.sun.faces.lifecycle.ProcessValidationsPhase.execute(ProcessValidationsPhase.java:100)
       at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:243)
       at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:113)
       at javax.faces.webapp.FacesServlet.service(FacesServlet.java:244)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at com.example.website.web.MyFilter.doFilter(MyFilter.java:61)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
       at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
       at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
       at org.jboss.web.tomcat.tc5.session.ClusteredSessionValve.invoke(ClusteredSessionValve.java:95)
       at org.jboss.web.tomcat.tc5.session.JvmRouteValve.invoke(JvmRouteValve.java:84)
       at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
       at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
       at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
       at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
       at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
       at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
       at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
       at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
       at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
       at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
       at java.lang.Thread.run(Thread.java:595)

      ...despite the fact that the component is found by Seam:
      2006-06-04 10:43:06,608 INFO [Component] Component: registrar, scope: EVENT, type: STATEFUL_SESSION_BEAN, class: com.example.ejb.web.RegistrarBean, JNDI: sn/RegistrarBean/local


      As a work-around, I have found that if I put the managed-bean declaration back in faces-config.xml, things begin working again. JSF acknowledges the managed bean/property identifier, and Seam overrides it with the appropriate component. The only problem identified with this so far is that it drowns my logs with the following warnings:
      ...
      2006-06-04 12:43:07,926 WARN [SeamVariableResolver] Seam component hides managed bean with same name
      2006-06-04 12:43:07,926 WARN [SeamVariableResolver] Seam component hides managed bean with same name
      2006-06-04 12:43:07,942 WARN [SeamVariableResolver] Seam component hides managed bean with same name
      2006-06-04 12:43:07,942 WARN [SeamVariableResolver] Seam component hides managed bean with same name
      2006-06-04 12:43:07,957 WARN [SeamVariableResolver] Seam component hides managed bean with same name
      ...

      Anyone else encounter this problem yet? Is it a known issue? Is the problem likely something broken in the RI nightly? Or is this the result of a legit JSF implementation change that Seam has to adjust for? I'm happy to open an issue with either or both projects, but I don't really know enough to know where to go.

      Thanks for the help and/or direction,
      Jonn