ICEfaces
  1. ICEfaces
  2. ICE-7942

StringIndexOutOfBoundsException when attempting a push on a stale view

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: EE-1.8.2.GA_P03
    • Fix Version/s: 1.8.3, EE-1.8.2.GA_P04
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      Seam 2.2, Weblogic 10.3.5, just-ice.jar + RunnableRenderer run() fix

      Description

      The following exception is thrown when attempting a push to a non existent view after session expiry. This exception has no functional impact but does clutter the log files. Full exception attached to the case.

      [ERROR] 04:34 (PersistentFacesState.java:execute:295)
      Exception occured during execute push on Unknown View

      javax.faces.FacesException: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
      at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:128)
      at com.sun.faces.lifecycle.RestoreViewPhase.doPhase(RestoreViewPhase.java:102)
      at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:118)
      at com.icesoft.faces.webapp.xmlhttp.PersistentFacesState.execute(PersistentFacesState.java:286)
      at com.icesoft.faces.webapp.xmlhttp.PersistentFacesState.executeAndRender(PersistentFacesState.java:312)
      ....................
      Caused by: java.lang.StringIndexOutOfBoundsException: String index out of range: -1
      at java.lang.String.substring(String.java:1937)
      at com.sun.faces.application.StateManagerImpl.restoreView(StateManagerImpl.java:175)
      at org.jboss.seam.jsf.SeamStateManager.restoreView(SeamStateManager.java:76)
      at com.icesoft.faces.application.D2DViewHandler.restoreView(D2DViewHandler.java:258)
      at com.sun.faces.lifecycle.RestoreViewPhase.execute(RestoreViewPhase.java:179)
      at com.sun.faces.lifecycle.Phase.doPhase(Phase.java:100)

      There are two ways to reproduce the issue in the sample:

      1. Bounce the server, reload the page via the NIC popup, and click the link to request a session render.
      2. Wait for the session to expire, reload, and again click the link to call the SessionRenderer.

      The just-ice.jar being used (SVN details below), has a fix that does reduce the frequency of the exception, which previously was being thrown after each requestRender call. The added fix was to add an extra catch block to the run() in RunnableRenderer like so:

      } catch (FacesException e) {
      renderable.renderingException(new TransientRenderingException(e));
      }

        Activity

        Repository Revision Date User Message
        ICEsoft Public SVN Repository #28521 Mon Mar 26 10:15:29 MDT 2012 ted.goddard dispose views that cannot be identified during push (ICE-7942)
        Files Changed
        Commit graph MODIFY /icefaces/trunk/icefaces/core/src/com/icesoft/faces/webapp/xmlhttp/PersistentFacesState.java

          People

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

            Dates

            • Created:
              Updated:
              Resolved: