ICEfaces
  1. ICEfaces
  2. ICE-6469

CompressDOM breaks navigation in 2.0

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.0.0
    • Fix Version/s: 2.0.1
    • Component/s: Bridge
    • Labels:
      None
    • Environment:
      Tomcat 6, Glassfish V3
    • Workaround Exists:
      Yes
    • Workaround Description:
      Hide
      Remove the following parameter from the web.xml:

        <context-param>
          <param-name>org.icefaces.compressDOM</param-name>
          <param-value>true</param-value>
        </context-param>
      Show
      Remove the following parameter from the web.xml:   <context-param>     <param-name>org.icefaces.compressDOM</param-name>     <param-value>true</param-value>   </context-param>

      Description

      For this particular scenario, the user is unable to navigate from PageA to PageB due to the compressDOM parameter being set to true in the web.xml. The FastInfoSet library has been included in the application and the following can be seen in the Firebug console and server logs:

      1. Firebug + deployed on Glassfish V3

      [window] the response does not contain XML data bridge.js.xhtml (line 1188)
      [window] HTTP error [code: 500]: There was an error communicating with the server, status: 500

      2. Firebug + deployed on Tomcat 6

      isXMLResponse is not defined
      [Break On This Error] broadcast(serverErrorL... isXMLResponse ? xmlContent : null]);

      3. Server logs for both servers

      java.lang.NullPointerException
      at org.icefaces.impl.util.DOMUtils.compareNodes(DOMUtils.java:341)
      at org.icefaces.impl.util.DOMUtils.nodeDiff(DOMUtils.java:318)
      at org.icefaces.impl.util.DOMUtils.domDiff(DOMUtils.java:302)
      ........
      [#|2011-01-12T12:15:09.815-0600|SEVERE|glassfish3.0.1|org.icefaces.impl.context.DOMResponseWriter|_ThreadID=26;_ThreadName=Thread-1;|Failed to restore old DOM
      java.lang.NullPointerException
      at java.io.ByteArrayInputStream.<init>(ByteArrayInputStream.java:89)
      ........
      etc..

        Activity

        Tyler Johnson created issue -
        Tyler Johnson made changes -
        Field Original Value New Value
        Salesforce Case [5007000000F7NWJ]
        Ken Fyten made changes -
        Fix Version/s 2.0.1 [ 10255 ]
        Assignee Ted Goddard [ ted.goddard ]
        Hide
        Ken Fyten added a comment -

        Tyler to attach test case.

        Show
        Ken Fyten added a comment - Tyler to attach test case.
        Repository Revision Date User Message
        ICEsoft Public SVN Repository #23822 Wed Jan 19 11:35:42 MST 2011 ted.goddard check for null before compressDOM parsing (ICE-6469)
        Files Changed
        Commit graph MODIFY /icefaces2/trunk/icefaces/core/src/main/java/org/icefaces/impl/context/DOMResponseWriter.java
        Hide
        Ted Goddard added a comment - - edited

        Reproduced by setting compressDOM=true for the "basic" application and configuring both icefaces.xhtml and nonicefaces.xhtml to use ICEfaces rendering. commandLink does not cause the exception but commandButton does. The difference appears to be the fact that navigation via the buttons does not involve a redirect.

        Show
        Ted Goddard added a comment - - edited Reproduced by setting compressDOM=true for the "basic" application and configuring both icefaces.xhtml and nonicefaces.xhtml to use ICEfaces rendering. commandLink does not cause the exception but commandButton does. The difference appears to be the fact that navigation via the buttons does not involve a redirect.
        Hide
        Ted Goddard added a comment -

        Slightly deeper stack trace:

        java.lang.NullPointerException
        at org.icefaces.impl.util.DOMUtils.compareNodes(DOMUtils.java:341)
        at org.icefaces.impl.util.DOMUtils.nodeDiff(DOMUtils.java:318)
        at org.icefaces.impl.util.DOMUtils.domDiff(DOMUtils.java:302)
        at org.icefaces.impl.context.DOMPartialViewContext.domDiff(DOMPartialViewContext.java:249)
        at org.icefaces.impl.context.DOMPartialViewContext.processPartial(DOMPartialViewContext.java:159)
        at javax.faces.component.UIViewRoot.encodeChildren(UIViewRoot.java:981)
        at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1756)
        at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:390)
        at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:131)
        at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:121)
        at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
        at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139)
        at javax.faces.webapp.FacesServlet.service(FacesServlet.java:396)

        Show
        Ted Goddard added a comment - Slightly deeper stack trace: java.lang.NullPointerException at org.icefaces.impl.util.DOMUtils.compareNodes(DOMUtils.java:341) at org.icefaces.impl.util.DOMUtils.nodeDiff(DOMUtils.java:318) at org.icefaces.impl.util.DOMUtils.domDiff(DOMUtils.java:302) at org.icefaces.impl.context.DOMPartialViewContext.domDiff(DOMPartialViewContext.java:249) at org.icefaces.impl.context.DOMPartialViewContext.processPartial(DOMPartialViewContext.java:159) at javax.faces.component.UIViewRoot.encodeChildren(UIViewRoot.java:981) at javax.faces.component.UIComponent.encodeAll(UIComponent.java:1756) at com.sun.faces.application.view.FaceletViewHandlingStrategy.renderView(FaceletViewHandlingStrategy.java:390) at com.sun.faces.application.view.MultiViewHandler.renderView(MultiViewHandler.java:131) at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:121) at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101) at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:139) at javax.faces.webapp.FacesServlet.service(FacesServlet.java:396)
        Hide
        Ted Goddard added a comment -

        FastInfoset was returning an empty document when the null serialized form was parsed. The fix was to check for a null byte array before parsing.

        Show
        Ted Goddard added a comment - FastInfoset was returning an empty document when the null serialized form was parsed. The fix was to check for a null byte array before parsing.
        Ted Goddard made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Ken Fyten made changes -
        Status Resolved [ 5 ] Closed [ 6 ]

          People

          • Assignee:
            Ted Goddard
            Reporter:
            Tyler Johnson
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: