Details
-
Type: Bug
-
Status: Closed
-
Priority: Major
-
Resolution: Fixed
-
Affects Version/s: 2.0.0
-
Fix Version/s: 2.0.1
-
Component/s: ICE-Components
-
Labels:None
-
Environment:Mojarra 2.1.1-b02 and ICEfaces 2 Compat menuBar and menuPopup
Description
When doing a postback with a form that contains a menuBar or menuPopup, the state restoration code is throwing a NPE.
This can only be duplicated by using svn revision 24115, from ICE-6649, of: icefaces2/lib/jsf-api.jar and jsf-impl.jar. The next revision of those jars in our svn contains the earlier Mojarra 2.1.1-b01 code, which works fine.
From Ted's analysis of the Mojarra code, the problem is that on state restore there exists state for which no component can be found, and the code assumes the component will be found, and throws a NPE. A trivial solution would be to not worry about having extra state with no corresponding component. But, since there's no guarantee that a change of that nature will happen, we'll need to see what we can do on our end.
So, we know that Mojarra is saving state for components that do not exist in the view upon restore. And from the clientIds, they are temporary helper components that the MenuItemRenderer creates to accomplish its rendering. The exception is not thrown by the selectInputDate component, which also dynamically adds helper components to the view.