ICEfaces
  1. ICEfaces
  2. ICE-4325

Bug in MainServlet, Jetty continuation does not work anymore, RetryRequest exception from Jetty get caught and not rethrown

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Duplicate
    • Affects Version/s: 1.8
    • Fix Version/s: 1.8.1
    • Component/s: Framework
    • Labels:
      None
    • Environment:
      Jetty 6.1.16, IceFaces tutorial

      Description

      RetryRequest get caught in MainServlet.java due to ICE-4261
      The following causes the problem:
                  //ICE-4261: We cannot wrap RuntimeExceptions as ServletExceptions because of support for Jetty
                  //Continuations. However, if the message of a RuntimeException is null, Tomcat won't
                  //properly redirect to the configured error-page. So we need a new RuntimeException
                  //that actually includes a message.
                  if( e.getMessage() != null ){
                      throw e;
                  }
                  throw new RuntimeException("no message available",e);
      I propose the following fix:
      if (e.getMessage() != null || e.getClass().getCanonicalName().equals("org.mortbay.jetty.RetryRequest")) {
                      throw e;
                  }
                  throw new RuntimeException("no message available",e);

      Unfortunately I was writing a detailed review and I lost it. Damn firefox...

        Issue Links

          Activity

          Jerome Bonnet created issue -
          Jerome Bonnet made changes -
          Field Original Value New Value
          Attachment MainServlet.java [ 11655 ]
          Deryk Sinotte made changes -
          Assignee Deryk Sinotte [ deryk.sinotte ]
          Deryk Sinotte made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Fix Version/s 1.8.1 [ 10170 ]
          Resolution Duplicate [ 3 ]
          Deryk Sinotte made changes -
          Link This issue depends on ICE-4261 [ ICE-4261 ]
          Ken Fyten made changes -
          Status Resolved [ 5 ] Closed [ 6 ]

            People

            • Assignee:
              Deryk Sinotte
              Reporter:
              Jerome Bonnet
            • Votes:
              1 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: