6 Replies Latest reply on Oct 8, 2005 3:57 PM by Gavin King

    binding probelm

    Deniss Parhomenko Newbie

      Hi.

      I use Seam together with ADF Faces.

      When I try to use binding attribute i receive exception when press any button on page (may be it because i use ADF):

      java.lang.IllegalStateException: No conversation context active
       at org.jboss.seam.ScopeType.getContext(Unknown Source)
       at org.jboss.seam.Component.newInstance(Unknown Source)
       at org.jboss.seam.Component.getInstance(Unknown Source)
       at org.jboss.seam.jsf.SeamVariableResolver.resolveVariable(Unknown Source)
       at oracle.adfinternal.view.faces.el.AdfFacesVariableResolver.resolveVariable(AdfFacesVariableResolver.java:40)
       at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyELContext.java:130)
       at com.sun.el.parser.AstIdentifier.getValue(AstIdentifier.java:44)
       at com.sun.el.parser.AstValue.getTarget(AstValue.java:41)
       at com.sun.el.parser.AstValue.isReadOnly(AstValue.java:104)
       at com.sun.el.ValueExpressionImpl.isReadOnly(ValueExpressionImpl.java:221)
       at com.sun.facelets.el.TagValueExpression.isReadOnly(TagValueExpression.java:82)
       at com.sun.facelets.el.LegacyValueBinding.isReadOnly(LegacyValueBinding.java:82)
       at org.apache.myfaces.lifecycle.LifecycleImpl.recursivelyHandleComponentReferencesAndSetValid(LifecycleImpl.java:364)
       at org.apache.myfaces.lifecycle.LifecycleImpl.recursivelyHandleComponentReferencesAndSetValid(LifecycleImpl.java:374)
       at org.apache.myfaces.lifecycle.LifecycleImpl.recursivelyHandleComponentReferencesAndSetValid(LifecycleImpl.java:374)
       at org.apache.myfaces.lifecycle.LifecycleImpl.restoreView(LifecycleImpl.java:151)
       at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:66)
       at javax.faces.webapp.FacesServlet.service(FacesServlet.java:94)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:356)
       at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:325)
       at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:190)
       at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:87)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(Unknown Source)
       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:81)
       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.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
       at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:157)
       at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
       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:856)
       at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
       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)

      JSP
      <h:outputText id="id" value="#{reportProject.id}" binding="#{editReportProject.idB}"/>

      Jaca class
      @Name("editReportProject")
      @Scope(CONVERSATION)
      @Intercept(InterceptionType.ALWAYS)
      @Conversational(ifNotBegunOutcome="welcome")
      
      ...
      
       public javax.faces.component.html.HtmlOutputText getIdB() {
       return idB;
       }
      
       public void setIdB(javax.faces.component.html.HtmlOutputText inB) {
       //javax.faces.component.html.HtmlOutputText
       this.idB = idB;
       }
      


        • 1. Re: binding probelm
          Jacob Hookom Newbie

          reference the Seam documentation about what elements need to be placed in your faces-config.

          Or have you already done that?

          • 2. Re: binding probelm
            Deniss Parhomenko Newbie

            Withou binding attribute all ADF components work perfectly, but if I put binding attribute to eny element, I recieve exception on any form action

            • 3. Re: binding probelm
              Deniss Parhomenko Newbie

              Without ADF I also receive exception

              java.lang.IllegalStateException: No conversation context active
               at org.jboss.seam.ScopeType.getContext(Unknown Source)
               at org.jboss.seam.Component.newInstance(Unknown Source)
               at org.jboss.seam.Component.getInstance(Unknown Source)
               at org.jboss.seam.jsf.SeamVariableResolver.resolveVariable(Unknown Source)
               at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyELContext.java:130)
               at com.sun.el.parser.AstIdentifier.getValue(AstIdentifier.java:44)
               at com.sun.el.parser.AstValue.getTarget(AstValue.java:41)
               at com.sun.el.parser.AstValue.isReadOnly(AstValue.java:104)
               at com.sun.el.ValueExpressionImpl.isReadOnly(ValueExpressionImpl.java:221)
               at com.sun.facelets.el.TagValueExpression.isReadOnly(TagValueExpression.java:82)
               at com.sun.facelets.el.LegacyValueBinding.isReadOnly(LegacyValueBinding.java:82)
               at org.apache.myfaces.lifecycle.LifecycleImpl.recursivelyHandleComponentReferencesAndSetValid(LifecycleImpl.java:364)
               at org.apache.myfaces.lifecycle.LifecycleImpl.recursivelyHandleComponentReferencesAndSetValid(LifecycleImpl.java:374)
               at org.apache.myfaces.lifecycle.LifecycleImpl.recursivelyHandleComponentReferencesAndSetValid(LifecycleImpl.java:374)
               at org.apache.myfaces.lifecycle.LifecycleImpl.restoreView(LifecycleImpl.java:151)
               at org.apache.myfaces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:66)
               at javax.faces.webapp.FacesServlet.service(FacesServlet.java:94)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
               at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
               at org.apache.myfaces.component.html.util.ExtensionsFilter.doFilter(ExtensionsFilter.java:122)
               at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
               at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
               at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(Unknown Source)
               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:81)
               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.CustomPrincipalValve.invoke(CustomPrincipalValve.java:39)
               at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:157)
               at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
               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:856)
               at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
               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)


              • 4. Re: binding probelm
                Gavin King Master

                Seam doesn't like it when you reference conversation-scope components from the Restore View phase. So whatever EL expression is being evaluated to determine if something isReadOnly() should not use a conversation scoped component.

                • 5. Re: binding probelm
                  Deniss Parhomenko Newbie

                  Thats mean that, i can't use binding attribute at all ?

                  • 6. Re: binding probelm
                    Gavin King Master

                    um, i don't see why not

                    just dont point to a conversation scope component, i guess