Details

    • Type: New Feature New Feature
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.7.2
    • Component/s: ICE-Components
    • Labels:
      None
    • Environment:
      n/a

      Description

      We should open our new ResourceRegistry api through a component.

      <ice:outputResource resource="#{bean.resource}"/>

      Users could use our own resource implementations or implement their own Resource classes.
      1. ICE-2348.patch
        34 kB
        Mircea Toma

        Issue Links

          Activity

          Hide
          Kristian Luck added a comment -

          Mircea Toma noted that 'The renderer needs to render a target="blank" attribute..." I'm new to ICEfaces, but this seems strikingly similar to the reserved [link] target attribute value of "_blank", which has the following special meaning: "The user agent should load the designated document in a new, unnamed window." (http://www.w3.org/TR/html401/types.html#type-frame-target). Should this have been made "_blank" instead of "blank"?

          Show
          Kristian Luck added a comment - Mircea Toma noted that 'The renderer needs to render a target="blank" attribute..." I'm new to ICEfaces, but this seems strikingly similar to the reserved [link] target attribute value of "_blank", which has the following special meaning: "The user agent should load the designated document in a new, unnamed window." ( http://www.w3.org/TR/html401/types.html#type-frame-target ). Should this have been made "_blank" instead of "blank"?
          Hide
          Asdf Asdf added a comment -

          hello!

          i think there is still a bug in the OutputResourceComponent when using EL for the fileName attribute. i basically downloaded the .war file attached to this case, and added a few lines so it should be easily reproducible:

          in OutputResourceBean.java:

          public String getDynamicFileName()

          { return "i_am_almost_dynamic.pdf"; }

          and in outputResource.jspx:

          <cust:outputResource id="otherPdf"
          resource="#

          {bean.pdfResource}

          "
          mimeType="application/pdf"
          value="Click to load pdf with dynamic filename"
          fileName="#

          {bean.dynamicFileName}

          "
          />

          after clicking on "Click to load pdf with dynamic filename" the app dies with the following stack trace:

          StandardWrapperValve[Blocking Servlet]: PWC1406: Servlet.service() for servlet Blocking Servlet threw exception
          java.lang.NullPointerException: FacesContext -> null
          at javax.faces.component.ValueBindingValueExpressionAdapter.getValue(ValueBindingValueExpressionAdapter.java:98)
          at com.icesoft.faces.component.outputResource.OutputResource.getFileName(OutputResource.java:84)
          at com.icesoft.faces.component.outputResource.OutputResource$1.withOptions(OutputResource.java:46)
          at com.icesoft.faces.webapp.http.core.ResourceDispatcher$ResourceServer.respond(ResourceDispatcher.java:120)
          at com.icesoft.faces.webapp.http.common.standard.CompressingServer$CompressingRequest$1.respond(CompressingServer.java:49)
          at com.icesoft.faces.webapp.http.servlet.ServletRequestResponse.respondWith(ServletRequestResponse.java:161)
          at com.icesoft.faces.webapp.http.servlet.ThreadBlockingAdaptingServlet$ThreadBlockingRequestResponse.respondWith(ThreadBlockingAdaptingServlet.java:36)
          at com.icesoft.faces.webapp.http.common.standard.CompressingServer$CompressingRequest.respondWith(CompressingServer.java:45)
          at com.icesoft.faces.webapp.http.core.ResourceDispatcher$ResourceServer.service(ResourceDispatcher.java:115)
          at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer$Matcher.serviceOnMatch(PathDispatcherServer.java:50)
          at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer.service(PathDispatcherServer.java:19)
          at com.icesoft.faces.webapp.http.common.standard.CompressingServer.service(CompressingServer.java:29)
          at com.icesoft.faces.webapp.http.core.ResourceDispatcher.service(ResourceDispatcher.java:39)
          at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer$Matcher.serviceOnMatch(PathDispatcherServer.java:50)
          at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer.service(PathDispatcherServer.java:19)
          at com.icesoft.faces.webapp.http.servlet.ThreadBlockingAdaptingServlet.service(ThreadBlockingAdaptingServlet.java:19)
          at com.icesoft.faces.webapp.http.servlet.EnvironmentAdaptingServlet.service(EnvironmentAdaptingServlet.java:63)
          at com.icesoft.faces.webapp.http.servlet.MainSessionBoundServlet.service(MainSessionBoundServlet.java:151)
          at com.icesoft.faces.webapp.http.servlet.SessionDispatcher.service(SessionDispatcher.java:54)
          at com.icesoft.faces.webapp.http.servlet.PathDispatcher$Matcher.serviceOnMatch(PathDispatcher.java:52)
          at com.icesoft.faces.webapp.http.servlet.PathDispatcher.service(PathDispatcher.java:29)
          at com.icesoft.faces.webapp.http.servlet.MainServlet.service(MainServlet.java:82)
          at javax.servlet.http.HttpServlet.service(HttpServlet.java:831)
          at com.icesoft.faces.webapp.xmlhttp.BlockingServlet.service(BlockingServlet.java:46)
          at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:317)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
          at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390)
          at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230)
          at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198)
          at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:288)
          at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271)
          at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202)
          at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
          at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
          at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94)
          at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206)
          at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
          at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
          at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
          at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
          at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150)
          at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632)
          at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577)
          at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571)
          at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080)
          at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:272)
          at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637)
          at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568)
          at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813)
          at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:341)
          at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:263)
          at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:214)
          at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265)
          at com.sun.enterprise.web.connector.grizzly.ssl.SSLWorkerThread.run(SSLWorkerThread.java:106)

          i will attached my .war file after this message.
          my environment is netbeans 6.5, icefaces from svn (29.09.2008), glassfish2 that was bundled with netbeans.

          best regards, armin walland

          Show
          Asdf Asdf added a comment - hello! i think there is still a bug in the OutputResourceComponent when using EL for the fileName attribute. i basically downloaded the .war file attached to this case, and added a few lines so it should be easily reproducible: in OutputResourceBean.java: public String getDynamicFileName() { return "i_am_almost_dynamic.pdf"; } and in outputResource.jspx: <cust:outputResource id="otherPdf" resource="# {bean.pdfResource} " mimeType="application/pdf" value="Click to load pdf with dynamic filename" fileName="# {bean.dynamicFileName} " /> after clicking on "Click to load pdf with dynamic filename" the app dies with the following stack trace: StandardWrapperValve [Blocking Servlet] : PWC1406: Servlet.service() for servlet Blocking Servlet threw exception java.lang.NullPointerException: FacesContext -> null at javax.faces.component.ValueBindingValueExpressionAdapter.getValue(ValueBindingValueExpressionAdapter.java:98) at com.icesoft.faces.component.outputResource.OutputResource.getFileName(OutputResource.java:84) at com.icesoft.faces.component.outputResource.OutputResource$1.withOptions(OutputResource.java:46) at com.icesoft.faces.webapp.http.core.ResourceDispatcher$ResourceServer.respond(ResourceDispatcher.java:120) at com.icesoft.faces.webapp.http.common.standard.CompressingServer$CompressingRequest$1.respond(CompressingServer.java:49) at com.icesoft.faces.webapp.http.servlet.ServletRequestResponse.respondWith(ServletRequestResponse.java:161) at com.icesoft.faces.webapp.http.servlet.ThreadBlockingAdaptingServlet$ThreadBlockingRequestResponse.respondWith(ThreadBlockingAdaptingServlet.java:36) at com.icesoft.faces.webapp.http.common.standard.CompressingServer$CompressingRequest.respondWith(CompressingServer.java:45) at com.icesoft.faces.webapp.http.core.ResourceDispatcher$ResourceServer.service(ResourceDispatcher.java:115) at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer$Matcher.serviceOnMatch(PathDispatcherServer.java:50) at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer.service(PathDispatcherServer.java:19) at com.icesoft.faces.webapp.http.common.standard.CompressingServer.service(CompressingServer.java:29) at com.icesoft.faces.webapp.http.core.ResourceDispatcher.service(ResourceDispatcher.java:39) at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer$Matcher.serviceOnMatch(PathDispatcherServer.java:50) at com.icesoft.faces.webapp.http.common.standard.PathDispatcherServer.service(PathDispatcherServer.java:19) at com.icesoft.faces.webapp.http.servlet.ThreadBlockingAdaptingServlet.service(ThreadBlockingAdaptingServlet.java:19) at com.icesoft.faces.webapp.http.servlet.EnvironmentAdaptingServlet.service(EnvironmentAdaptingServlet.java:63) at com.icesoft.faces.webapp.http.servlet.MainSessionBoundServlet.service(MainSessionBoundServlet.java:151) at com.icesoft.faces.webapp.http.servlet.SessionDispatcher.service(SessionDispatcher.java:54) at com.icesoft.faces.webapp.http.servlet.PathDispatcher$Matcher.serviceOnMatch(PathDispatcher.java:52) at com.icesoft.faces.webapp.http.servlet.PathDispatcher.service(PathDispatcher.java:29) at com.icesoft.faces.webapp.http.servlet.MainServlet.service(MainServlet.java:82) at javax.servlet.http.HttpServlet.service(HttpServlet.java:831) at com.icesoft.faces.webapp.xmlhttp.BlockingServlet.service(BlockingServlet.java:46) at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:411) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:317) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198) at org.netbeans.modules.web.monitor.server.MonitorFilter.doFilter(MonitorFilter.java:390) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:230) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:198) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:288) at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:271) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:202) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577) at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:94) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:206) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:150) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:632) at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:577) at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:571) at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:1080) at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:272) at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.invokeAdapter(DefaultProcessorTask.java:637) at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.doProcess(DefaultProcessorTask.java:568) at com.sun.enterprise.web.connector.grizzly.DefaultProcessorTask.process(DefaultProcessorTask.java:813) at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.executeProcessorTask(DefaultReadTask.java:341) at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:263) at com.sun.enterprise.web.connector.grizzly.DefaultReadTask.doTask(DefaultReadTask.java:214) at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:265) at com.sun.enterprise.web.connector.grizzly.ssl.SSLWorkerThread.run(SSLWorkerThread.java:106) i will attached my .war file after this message. my environment is netbeans 6.5, icefaces from svn (29.09.2008), glassfish2 that was bundled with netbeans. best regards, armin walland
          Hide
          Asdf Asdf added a comment -

          slightly modified version of the OutputResourceComponent-demoapp to illustrate exception when using EL in "fileName" attribute.

          Show
          Asdf Asdf added a comment - slightly modified version of the OutputResourceComponent-demoapp to illustrate exception when using EL in "fileName" attribute.
          Hide
          Ken Fyten added a comment -

          Re-opened. Looks like we forgot to commit some files for this that are required, and QA didn't get the tests so it didn't fail... (oops).

          Let's make this right for 1.7.2 final.

          Show
          Ken Fyten added a comment - Re-opened. Looks like we forgot to commit some files for this that are required, and QA didn't get the tests so it didn't fail... (oops). Let's make this right for 1.7.2 final.
          Hide
          Philip Breau added a comment -

          checked into 1.7 branch and head

          Show
          Philip Breau added a comment - checked into 1.7 branch and head

            People

            • Assignee:
              Philip Breau
              Reporter:
              Philip Breau
            • Votes:
              19 Vote for this issue
              Watchers:
              20 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: