myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Max Starets (JIRA)" <...@myfaces.apache.org>
Subject [jira] Updated: (TRINIDAD-1817) fileDownloadActionListeners needs to delay retrieving OutputStream from the response until something needs to be written to the stream
Date Fri, 28 May 2010 14:54:40 GMT

     [ https://issues.apache.org/jira/browse/TRINIDAD-1817?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Max Starets updated TRINIDAD-1817:
----------------------------------

        Status: Resolved  (was: Patch Available)
    Resolution: Fixed

Committed rev.  949196

> fileDownloadActionListeners needs to delay retrieving OutputStream from the response
until something needs to be written to the stream
> --------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: TRINIDAD-1817
>                 URL: https://issues.apache.org/jira/browse/TRINIDAD-1817
>             Project: MyFaces Trinidad
>          Issue Type: Bug
>    Affects Versions: 2.0.0.3-core
>            Reporter: Max Starets
>            Assignee: Max Starets
>         Attachments: trinidad-1817.patch
>
>
> The issue may be demonstrated by taking our fileDownloadActionListener demo and modifying
it to run with Facelets.
> After you click on the 'Click for Error" button, you will get an UnsupportedOperationException
instead of the expected FacesMessage.
> The exception is thrown because we calling getOutputStream(), but not completing the
response when we want to report an error.
> JSF later calls getWriter(), which is causing UnsupportedOperationException.
> This problem does not show up with JSPs because of the side effect of the JSP engine
dispatch - getWriter() simply succeeds.
> The solution is to create a proxy OutputStream that retrieves the delegate stream only
when it needs to write.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message