ICEfaces
  1. ICEfaces
  2. ICE-10566

ace:list - NullPointerException thrown when using a null value binding

    Details

    • Assignee Priority:
      P2
    • Support Case References:
    • Workaround Exists:
      Yes
    • Workaround Description:
      Use an empty list or rendered attribute to display the component when it is not empty.

      Description

      When using a list that is null with the ace:list component, an exception is thrown when navigating away from the page:

       javax.faces.FacesException
      at com.sun.faces.lifecycle.ApplyRequestValuesPhase.execute(ApplyRequestValuesPhase.java:86)
      at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:101)
      at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:198)
      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:646)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:291)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.apache.tomcat.websocket.server.WsFilter.doFilter(WsFilter.java:52)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:393)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:239)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:219)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:106)
      at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:503)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:136)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:79)
      at org.apache.catalina.valves.AbstractAccessLogValve.invoke(AbstractAccessLogValve.java:610)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:88)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:526)
      at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1078)
      at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:655)
      at org.apache.coyote.http11.Http11NioProtocol$Http11ConnectionHandler.process(Http11NioProtocol.java:222)
      at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.doRun(NioEndpoint.java:1566)
      at org.apache.tomcat.util.net.NioEndpoint$SocketProcessor.run(NioEndpoint.java:1523)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at org.apache.tomcat.util.threads.TaskThread$WrappingRunnable.run(TaskThread.java:61)
      at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.NullPointerException
      at org.icefaces.ace.component.list.ListDecoder.insertImmigrants(ListDecoder.java:302)
      at org.icefaces.ace.component.list.ListRenderer.decode(ListRenderer.java:74)
      at javax.faces.component.UIComponentBase.decode(UIComponentBase.java:831)
      at org.icefaces.impl.component.UISeriesBase.processDecodes(UISeriesBase.java:523)
      at javax.faces.component.UIForm.processDecodes(UIForm.java:225)
      at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1221)
      at javax.faces.component.UIComponentBase.processDecodes(UIComponentBase.java:1221)
      at javax.faces.component.UIViewRoot.processDecodes(UIViewRoot.java:929)
      at com.sun.faces.lifecycle.ApplyRequestValuesPhase.execute(ApplyRequestValuesPhase.java:78)
      ... 28 more

        Activity

        Hide
        Arran Mccullough added a comment -

        Attached test case that shows this issue.

        Steps:

        • Load welcomeICEfaces.jsf
        • Click the Page link.
        • A NPE is thrown.
        Show
        Arran Mccullough added a comment - Attached test case that shows this issue. Steps: Load welcomeICEfaces.jsf Click the Page link. A NPE is thrown.
        Hide
        Arturo Zambrano added a comment -

        Committed fix to the 4.0 trunk at revision 44297 and to the 3.3 EE maintenance branch at revision 44298. Added conditionals for non-null values before performing operations on the value objects.

        Show
        Arturo Zambrano added a comment - Committed fix to the 4.0 trunk at revision 44297 and to the 3.3 EE maintenance branch at revision 44298. Added conditionals for non-null values before performing operations on the value objects.
        Hide
        Liana Munroe added a comment -

        Verified using attached test case. ICEfaces EE-4.0.0 Jenkins build 2 and EE-3.3.0 maintenance branch. Tomcat 7, IE 11, FF 34, Chrome 41.
        Server warning was seen when testing with ee-3.3.0 libs:
        Mar 26, 2015 1:58:12 PM javax.faces.component.UIViewRoot$ViewMap put
        WARNING: Setting non-serializable attribute value into ViewMap: (key: icefacesBe
        anDestroyRecorder, value class: org.icefaces.impl.application.IcefacesBeanDestro
        yRecorder)

        Show
        Liana Munroe added a comment - Verified using attached test case. ICEfaces EE-4.0.0 Jenkins build 2 and EE-3.3.0 maintenance branch. Tomcat 7, IE 11, FF 34, Chrome 41. Server warning was seen when testing with ee-3.3.0 libs: Mar 26, 2015 1:58:12 PM javax.faces.component.UIViewRoot$ViewMap put WARNING: Setting non-serializable attribute value into ViewMap: (key: icefacesBe anDestroyRecorder, value class: org.icefaces.impl.application.IcefacesBeanDestro yRecorder)

          People

          • Assignee:
            Arturo Zambrano
            Reporter:
            Arran Mccullough
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: