1 2 Previous Next 16 Replies Latest reply on Jan 18, 2007 5:52 PM by jalupa

    Seam doesn't play with ICEFaces

    hispeedsurfer

      My question is 'why this app work with pur Seam and MyFaces, but not with ICEFaces'

      1. Abstract editor class

      public abstract class AbstractEditorBean<T extends StandardEntity> extends AbstractEditorListeGemeinsames<T> implements Serializable {
       .
       .
       protected boolean neu;
      
       @Begin(nested=true, ifOutcome={"editor"})
       public String bearbeiten() {
      
       if (id == null) {
       addWarning(idError());
       return "main";
       }
      
       //Entity holen
       try {
       setEntity((T) em.find(getEntityClass(), Long.parseLong(id)));
       neu = false;
       if (getEntity() == null) throw new Exception();
       } catch (Exception ex) {
       addWarning(findenError());
       return null;
       }
      
       nachLaden();
      
       //Alles ok? Dann Editor anzeigen
       return "editor";
       }
       .
       .
       public boolean getNeu() {
       checkKorrekterAufruf();
       return neu;
       }
      .
      .
      }
      


      2. Measurement class
      @Stateful
      @Scope(ScopeType.CONVERSATION)
      @Name("messmitteltypEditor")
      @TransactionAttribute(TransactionAttributeType.NOT_SUPPORTED)
      public class MessmitteltypEditorBean extends AbstractEditorBean<Messmitteltyp> implements MessmitteltypEditor {
      
       @In(required=false) @Out(required=false)
       private Messmitteltyp messmitteltyp;
       .
       .
      }


      3. All changes to web.xml, faces-config.xml and lib dirs for ICEFaces as descriped here:http://support.icesoft.com/jive/servlet/KbServlet/download/623-102-847/SeamKBArticle.txt

      4. The xhtml pages:
      a)messmittelTypListe.xhtml
      <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <ui:composition xmlns="http://www.w3.org/1999/xhtml"
       xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:h="http://java.sun.com/jsf/html"
       xmlns:f="http://java.sun.com/jsf/core"
       xmlns:s="http://jboss.com/products/seam/taglib"
       xmlns:t="http://myfaces.apache.org/tomahawk"
       template="vorlage-liste.xhtml">
      
      <!-- content -->
      
      <ui:param name="ueberschrift" value="Messmitteltypen" />
      <ui:param name="editor" value="#{messmitteltypEditor}" />
      <ui:param name="liste" value="#{messmitteltypListe}" />
      <ui:param name="login" value="true" />
      
      <ui:define name="content">
      
       .....
      
      </ui:define>
      
      </ui:composition>
      


      b)
      Template
      vorlage-liste.xhtml -> this call AbstractEditor.bearbeiten
      <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <ui:composition xmlns="http://www.w3.org/1999/xhtml"
       xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:h="http://java.sun.com/jsf/html"
       xmlns:f="http://java.sun.com/jsf/core"
       xmlns:s="http://jboss.com/products/seam/taglib"
       xmlns:t="http://myfaces.apache.org/tomahawk"
       template="vorlage-grundgeruest.xhtml">
      .
      .
      .
      
       <t:dataTable var="zeile" value="#{liste.eintraege}"
       rendered="#{liste.eintraege.rowCount > 0}" styleClass="table">
      
       <ui:insert name="content" />
      
       <t:column styleClass="breite16">
       <h:commandLink action="#{editor.bearbeiten}"> <!-- this call AbstractEditor.bearbeiten() neu= true -->
       <f:param name="id" value="#{zeile.id}" />
       <h:graphicImage value="/img/edit.gif" />
       </h:commandLink>
       </t:column>
      
       </t:dataTable>


      c)
      Template
      vorlage-editor.xhtml -> Exception getting value of property neu of base of typ
      <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <ui:composition xmlns="http://www.w3.org/1999/xhtml"
       xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:h="http://java.sun.com/jsf/html"
       xmlns:f="http://java.sun.com/jsf/core"
       xmlns:s="http://jboss.com/products/seam/taglib"
       xmlns:t="http://myfaces.apache.org/tomahawk"
       template="vorlage-grundgeruest.xhtml">
      
       <!-- Hauptteil -->
      
       <ui:define name="hauptteil">
      
       <div class="section">
       <h1>
       #{ueberschrift}
       <i><h:outputText value="#{editor.entity}" rendered="#{!editor.neu}" /></i> <!-- Exception getting value of property neu of base of type...-->
       <h:outputText value="neu anlegen" rendered="#{editor.neu}" />
       </h1>
       </div>

      d)
      messmitteltypEditor.xhtml
      <!DOCTYPE composition PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
      <ui:composition xmlns="http://www.w3.org/1999/xhtml"
       xmlns:ui="http://java.sun.com/jsf/facelets"
       xmlns:h="http://java.sun.com/jsf/html"
       xmlns:f="http://java.sun.com/jsf/core"
       xmlns:s="http://jboss.com/products/seam/taglib"
       xmlns:t="http://myfaces.apache.org/tomahawk"
       xmlns:a4j="https://ajax4jsf.dev.java.net/ajax"
       xmlns:sandbox="http://myfaces.apache.org/sandbox"
       template="vorlage-editor.xhtml">
      
      <!-- content -->
      
      <ui:param name="ueberschrift" value="Messmitteltyp" />
      <ui:param name="editor" value="#{messmitteltypEditor}" />
      <ui:param name="login" value="true" />
      
      ...
      <ui:define name="content">
       ...
      

      at last the stack trace:
      09:33:39,577 ERROR [D2DFaceletViewHandler] Problem in renderResponse: /vorlage-editor.xhtml @17,75 rendered="#{!editor.neu}": Exception getting value of property neu of base of type : de.bosch.ccecp.mmd.action.MessmitteltypEditor$$EnhancerByCGLIB$$8423db5e
      javax.faces.el.EvaluationException: /vorlage-editor.xhtml @17,75 rendered="#{!editor.neu}": Exception getting value of property neu of base of type : de.bosch.ccecp.mmd.action.MessmitteltypEditor$$EnhancerByCGLIB$$8423db5e
       at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:60)
       at javax.faces.component.UIComponentBase.isRendered(UIComponentBase.java:1075)
       at javax.faces.component.UIComponentBase.encodeBegin(UIComponentBase.java:508)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:528)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.application.D2DViewHandler.renderResponse(D2DViewHandler.java:535)
       at com.icesoft.faces.facelets.D2DFaceletViewHandler.renderResponse(D2DFaceletViewHandler.java:273)
       at com.icesoft.faces.application.D2DViewHandler.renderView(D2DViewHandler.java:149)
       at org.ajax4jsf.framework.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:101)
       at org.ajax4jsf.framework.ajax.AjaxViewHandler.renderView(AjaxViewHandler.java:250)
       at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:384)
       at com.icesoft.faces.webapp.xmlhttp.PersistentFacesServlet.service(PersistentFacesServlet.java:394)
       at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
       at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
       at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
       at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:46)
       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.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:524)
       at org.jboss.web.tomcat.security.HttpServletRequestResponseValve.invoke(HttpServletRequestResponseValve.java:70)
       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.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
       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:619)
      Caused by: javax.faces.el.EvaluationException: Bean: de.bosch.ccecp.mmd.action.MessmitteltypEditor$$EnhancerByCGLIB$$8423db5e, property: neu
       at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:442)
       at org.apache.myfaces.el.PropertyResolverImpl.getValue(PropertyResolverImpl.java:82)
       at com.sun.facelets.el.LegacyELContext$LegacyELResolver.getValue(LegacyELContext.java:141)
       at com.sun.el.parser.AstValue.getValue(AstValue.java:117)
       at com.sun.el.parser.AstNot.getValue(AstNot.java:46)
       at com.sun.el.ValueExpressionImpl.getValue(ValueExpressionImpl.java:192)
       at com.sun.facelets.el.TagValueExpression.getValue(TagValueExpression.java:71)
       at com.sun.facelets.el.LegacyValueBinding.getValue(LegacyValueBinding.java:56)
       ... 43 more
      Caused by: java.lang.reflect.InvocationTargetException
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.apache.myfaces.el.PropertyResolverImpl.getProperty(PropertyResolverImpl.java:438)
       ... 50 more
      Caused by: java.lang.NullPointerException
       at org.jboss.seam.util.Parameters.convertMultiValueRequestParameter(Parameters.java:48)
       at org.jboss.seam.Component.injectParameters(Component.java:1151)
       at org.jboss.seam.Component.inject(Component.java:1114)
       at org.jboss.seam.interceptors.BijectionInterceptor.bijectTargetComponent(BijectionInterceptor.java:48)
       at sun.reflect.GeneratedMethodAccessor401.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
       at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
       at org.jboss.seam.interceptors.ManagedEntityIdentityInterceptor.aroundInvoke(ManagedEntityIdentityInterceptor.java:39)
       at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
       at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
       at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
       at org.jboss.seam.interceptors.OutcomeInterceptor.interceptOutcome(OutcomeInterceptor.java:23)
       at sun.reflect.GeneratedMethodAccessor399.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
       at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
       at org.jboss.seam.interceptors.ConversationInterceptor.endOrBeginLongRunningConversation(ConversationInterceptor.java:51)
       at sun.reflect.GeneratedMethodAccessor398.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
       at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
       at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
       at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
       at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
       at org.jboss.seam.intercept.SessionBeanInterceptor.aroundInvoke(SessionBeanInterceptor.java:49)
       at sun.reflect.GeneratedMethodAccessor397.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.ejb3.interceptor.InvocationContextImpl.proceed(InvocationContextImpl.java:118)
       at org.jboss.ejb3.interceptor.EJB3InterceptorsInterceptor.invoke(EJB3InterceptorsInterceptor.java:63)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.entity.ExtendedPersistenceContextPropagationInterceptor.invoke(ExtendedPersistenceContextPropagationInterceptor.java:57)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.entity.TransactionScopedEntityManagerInterceptor.invoke(TransactionScopedEntityManagerInterceptor.java:54)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.AllowedOperationsInterceptor.invoke(AllowedOperationsInterceptor.java:46)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.aspects.tx.TxPolicy.invokeInNoTx(TxPolicy.java:66)
       at org.jboss.aspects.tx.TxInterceptor$NotSupported.invoke(TxInterceptor.java:102)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.aspects.tx.TxPropagationInterceptor.invoke(TxPropagationInterceptor.java:76)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.stateful.StatefulInstanceInterceptor.invoke(StatefulInstanceInterceptor.java:83)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.aspects.security.AuthenticationInterceptor.invoke(AuthenticationInterceptor.java:77)
       at org.jboss.ejb3.security.Ejb3AuthenticationInterceptor.invoke(Ejb3AuthenticationInterceptor.java:102)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.ENCPropagationInterceptor.invoke(ENCPropagationInterceptor.java:47)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.asynchronous.AsynchronousInterceptor.invoke(AsynchronousInterceptor.java:106)
       at org.jboss.aop.joinpoint.MethodInvocation.invokeNext(MethodInvocation.java:101)
       at org.jboss.ejb3.stateful.StatefulContainer.localInvoke(StatefulContainer.java:203)
       at org.jboss.ejb3.stateful.StatefulLocalProxy.invoke(StatefulLocalProxy.java:98)
       at $Proxy487.getNeu(Unknown Source)
       at de.beffo.seam.helper.AbstractEditor$$FastClassByCGLIB$$d100690e.invoke(<generated>)
       at net.sf.cglib.proxy.MethodProxy.invoke(MethodProxy.java:149)
       at org.jboss.seam.intercept.RootInvocationContext.proceed(RootInvocationContext.java:45)
       at org.jboss.seam.intercept.ClientSideInterceptor$1.proceed(ClientSideInterceptor.java:73)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:55)
       at org.jboss.seam.interceptors.RemoveInterceptor.removeIfNecessary(RemoveInterceptor.java:39)
       at sun.reflect.GeneratedMethodAccessor396.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
       at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
       at org.jboss.seam.interceptors.ExceptionInterceptor.handleExceptions(ExceptionInterceptor.java:38)
       at sun.reflect.GeneratedMethodAccessor395.invoke(Unknown Source)
       at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
       at java.lang.reflect.Method.invoke(Method.java:597)
       at org.jboss.seam.util.Reflections.invoke(Reflections.java:18)
       at org.jboss.seam.intercept.Interceptor.aroundInvoke(Interceptor.java:169)
       at org.jboss.seam.intercept.SeamInvocationContext.proceed(SeamInvocationContext.java:64)
       at org.jboss.seam.intercept.RootInterceptor.createSeamInvocationContext(RootInterceptor.java:144)
       at org.jboss.seam.intercept.RootInterceptor.invokeInContexts(RootInterceptor.java:129)
       at org.jboss.seam.intercept.RootInterceptor.invoke(RootInterceptor.java:102)
       at org.jboss.seam.intercept.ClientSideInterceptor.interceptInvocation(ClientSideInterceptor.java:82)
       at org.jboss.seam.intercept.ClientSideInterceptor.intercept(ClientSideInterceptor.java:51)
       at de.bosch.ccecp.mmd.action.MessmitteltypEditor$$EnhancerByCGLIB$$8423db5e.getNeu(<generated>)
       ... 55 more
      


      Here the steps when I debug this app

      1. current page: messketteListe.xhtml - click: bearbeiten
      2. methode invoked: AbstractEditor.bearbeiten() -> set property neu=true -> outcome:"editor"
      3. from outcome:"editor" -> messmitteltypEditor.xhtml
      4. BANG. java.lang.NullPointerException (Exception getting value of property neu of base of type

      So whats going wrong here? Without ICEFaces the app working perfectly. In ICEFaces Forum they gave no advice.

      Thanks
      Andreas Franke

        • 1. Re: Seam doesn't play with ICEFaces
          jerome_082006

          Hello,

          I believe this is an Icefaces issue: request parameters (maps) are not properly initialized (cf. PersistentFacesServlet).

          Regards,
          Jerome.

          • 2. Re: Seam doesn't play with ICEFaces
            hispeedsurfer

            Hello,

            I think it's a bug like descriped here
            http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3991677#3991677

            Can it be?



            Thanks
            Andreas

            • 3. Re: Seam doesn't play with ICEFaces
              jerome_082006

              Yes, exactly, I had to face the same issue.

              This might help:
              http://www.icefaces.org/JForum/posts/list/2953.page

              Regards,
              Jerome.

              • 4. Re: Seam doesn't play with ICEFaces
                hispeedsurfer

                Hi Jerome,

                thank you for reply. I have tried to modify the PersistentFacesServlet.java as descriped. But in the icefaces.src.core package ELSetPropertiesRule.java is an error that getExpressionFactory() is undefined for type Application.

                When I try to export this package as jar file to my ice-application the following exception is thrown:

                java.lang.UnsupportedOperationException: Cannot set ServletRequest Parameter
                 at org.apache.myfaces.context.servlet.RequestParameterMap.setAttribute(RequestParameterMap.java:44)
                 at org.apache.myfaces.context.servlet.AbstractAttributeMap.put(AbstractAttributeMap.java:104)
                 at com.icesoft.faces.webapp.xmlhttp.PersistentFacesServlet.service(PersistentFacesServlet.java:341)
                 at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
                 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                 at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:46)
                 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.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:524)
                 at org.jboss.web.tomcat.security.HttpServletRequestResponseValve.invoke(HttpServletRequestResponseValve.java:70)
                 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.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
                 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:619)
                13:34:11,577 ERROR [[Persistent Faces Servlet]] Servlet.service() for servlet Persistent Faces Servlet threw exception
                java.lang.UnsupportedOperationException: Cannot set ServletRequest Parameter
                 at org.apache.myfaces.context.servlet.RequestParameterMap.setAttribute(RequestParameterMap.java:44)
                 at org.apache.myfaces.context.servlet.AbstractAttributeMap.put(AbstractAttributeMap.java:104)
                 at com.icesoft.faces.webapp.xmlhttp.PersistentFacesServlet.service(PersistentFacesServlet.java:341)
                 at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
                 at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
                 at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
                 at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:46)
                 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.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:524)
                 at org.jboss.web.tomcat.security.HttpServletRequestResponseValve.invoke(HttpServletRequestResponseValve.java:70)
                 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.jboss.web.tomcat.tc5.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:156)
                 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:619)
                


                What I have ToDo to solve this problem.


                Thanks
                andreas

                • 5. Re: Seam doesn't play with ICEFaces
                  jerome_082006

                  Hi Andreas,

                  I didn't get that exception. Did you manage to build Icefaces ?

                  Maybe you should ask someone at Icefaces.

                  Regards,
                  Jerome.

                  • 6. Re: Seam doesn't play with ICEFaces

                    Hello!

                    This is a bug in icefaces and I have a fix for it at home.

                    Sadly the icefaces people never read the JSF specification. They are using the request parameter map to share objects between different methods.

                    According to specs the request parameter map is unmutable so you get an UnsupportedOperationException.

                    I have a fix at home I will post here this evening.

                    Regards

                    Felix

                    P.S.: There are many such careless implementation mistakes. I stopped using Icefaces for that reason. I don't think it is ready for a production environment.

                    • 7. Re: Seam doesn't play with ICEFaces
                      hispeedsurfer

                      Hello Felix,

                      thank you for response. Can you please post the fix for this problem.


                      Thanks
                      andi

                      • 8. Re: Seam doesn't play with ICEFaces
                        gus888

                        From the ICEfaces forum, the new release of icefaces 1.5.2, which fixes lots of bugs on integration with Seam, will come in next week. We may try the new icefaces release with seam.
                        http://www.icefaces.org/JForum/posts/list/3325.page

                        • 9. Re: Seam doesn't play with ICEFaces

                          Hello!

                          I'm afraid I have deleted my latest version of icefaces. As I have already written I stopped using it. I do have a patch for the request parameter issue described in the link. I think it is somewhat cleaner:

                          diff -uNr icefaces.orig/core/src/com/icesoft/faces/context/BridgeExternalContext.java icefaces.patched/core/src/com/icesoft/faces/context/BridgeExternalContext.java
                          --- icefaces.orig/core/src/com/icesoft/faces/context/BridgeExternalContext.java 2006-11-23 14:30:42.000000000 +0100
                          +++ icefaces.patched/core/src/com/icesoft/faces/context/BridgeExternalContext.java 2006-12-31 01:29:31.265625000 +0100
                          @@ -433,9 +433,12 @@
                           * in the List is returned.
                           */
                          
                          +
                           /**
                           * populate the underlying hashtable
                           */
                          +
                          + // FIXME: Remove this method. Not needed anymore.
                           public synchronized void populateRequestParameters(Map requestParameters) {
                           Map valuesMap = getRequestParameterValuesMap();
                           if (valuesMap == null) {
                          @@ -447,15 +450,59 @@
                           filterRequestParameterMap();
                           }
                          
                          + public synchronized void populateRequestParameters() {
                          +
                          + // Only do this if it has not been done before
                          + if (requestParameterValuesMap == null) {
                          +
                          + requestParameterValuesMap = new RequestParameterValuesMap();
                          +
                          + if (null != servletRequest) {
                          + Enumeration names = servletRequest.getParameterNames();
                          + while (names.hasMoreElements()) {
                          + String name = (String) names.nextElement();
                          + requestParameterValuesMap.put(name, servletRequest.getParameter(name));
                          + }
                          + } else if (null != portletRequest) {
                          + Enumeration names = portletRequest.getParameterNames();
                          + while (names.hasMoreElements()) {
                          + String name = (String) names.nextElement();
                          + requestParameterValuesMap.put(name, portletRequest.getAttribute(name));
                          + }
                          + }
                          +
                          + requestParameterMap = new Hashtable();
                          +
                          + Iterator parameterNames = requestParameterValuesMap.keySet().iterator();
                          + Object nextParameterName = null, nextParameterValue = null;
                          + while (parameterNames.hasNext()) {
                          +
                          + nextParameterName = parameterNames.next();
                          + nextParameterValue = requestParameterValuesMap.get(nextParameterName);
                          + nextParameterValue = ((String[]) nextParameterValue)[0];
                          + requestParameterMap.put(nextParameterName, nextParameterValue);
                          + }
                          +
                          +
                          +
                          + }
                          +
                          + }
                          +
                           private Map requestParameterMap;
                          
                           public Map getRequestParameterMap() {
                          - if (requestParameterMap != null) {
                          - return requestParameterMap;
                          +
                          + if (requestParameterMap == null) {
                          +
                          + populateRequestParameters();
                          +
                           }
                          - return requestParameterMap = new Hashtable();
                          +
                          + return requestParameterMap;
                           }
                          
                          + // FIXME: Remove this method. Not needed anymore.
                           private void filterRequestParameterMap() {
                           if (requestParameterMap == null) {
                           requestParameterMap = new Hashtable();
                          @@ -479,10 +526,16 @@
                           /**
                           * returns null if you didn't first call populateRequestParameters.
                           * No it doesn't. Can't do that. Returns an empty map if populate hasn't
                          - * been called.
                          + * been called.
                           */
                           public Map getRequestParameterValuesMap() {
                          -
                          +
                          + if (requestParameterValuesMap == null) {
                          +
                          + populateRequestParameters();
                          +
                          + }
                          +
                           return requestParameterValuesMap;
                           }
                          
                          @@ -996,9 +1049,12 @@
                          
                           }
                          
                          +
                          +// FIXME: Does this inherit from AbstractMap or does it use a delegate? Plz not both!!!
                          +// FIXME: According to spec this should be immutable.
                           class RequestParameterValuesMap extends AbstractMap {
                          
                          - private Hashtable map = new Hashtable();
                          + private Map map = new Hashtable();
                          
                           public Object get(Object key) {
                           if (key == null) {
                          


                          I just checked in the original sources: The request parameters bug I fixed was somewhere else. The reason it crashed was exactly the same. Ithink in your case it is:
                          
                           facesContext.getExternalContext().getRequestParameterMap()
                           .put("viewNumber", String.valueOf(viewNumber));
                          
                          


                          Not sure what this is suppsoed to mean but according to specs you must not put additional values to the RequestParamterMap. If you have fixed this you will find another piece of code where icefaces puts some attribute in to the map to notify another component internally that this is a seam request.

                          The conclusion I drew from this mess is not to use Icefaces (yet!). I hope this helps you a little.

                          Regards

                          Felix

                          • 10. Re: Seam doesn't play with ICEFaces
                            jalupa

                            In fact it is a bug in MyFaces, they are implementing the JSF-specification, so they should make sure that the returned Map is immutable. I filed a bug report some while ago:
                            https://issues.apache.org/jira/browse/MYFACES-1517

                            • 11. Re: Seam doesn't play with ICEFaces

                              I disagree. The specification only says immutable but does not say what is supposed to happen when somebody _tries_ to modify it.

                              Throwing an UnsupportedOperationException is in my opinion reasonable. I haven't actually checked what the RI does but silently ignoring the attempt to add a request parameter is surely not an option.

                              If if the error was swallowed because whatever Icefaces is trying to achieve by putting the viewNumber into the map would ot be achieved.

                              So this is definitly a bug in Icefaces and this is one more reason why I would not recommend it.

                              Regards

                              Felix

                              • 12. Re: Seam doesn't play with ICEFaces
                                jalupa

                                Please read my post and the bug report again. The MyFaces implementation allows the request parameter map to be modified. The RI throws an UnsupportedOperationException (which is good and conform to the specification).
                                So, this is definitely a bug in MyFaces. You can't blaim the IceFaces people for this.

                                • 13. Re: Seam doesn't play with ICEFaces
                                  christian.bauer

                                  By the way, ICEFaces 1.5.2 is out and works better with Seam (this issue is fixed, for example).

                                  • 14. Re: Seam doesn't play with ICEFaces
                                    kukeltje

                                    I'll give icefaces 1.5.x a (re-)try in a few weeks. I've been running into so many problems that I've switched back to using Tomahawk (not Gavin's favourite, but a lot less troublesome for me)

                                    What I would certainly advise is to use seam cvs-head (1.1.1) since unexpected conversation endings is fixed there. Which prevents a part of the 'strange' behaviour of icefaces

                                    1 2 Previous Next