[ 
http://www.stripesframework.org/jira/browse/STS-630?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Ben Gunter resolved STS-630.
----------------------------

       Resolution: Cannot Reproduce
    Fix Version/s:     (was: Release 1.5.1)
                       (was: Release 1.6)

I couldn't reproduce this and haven't heard back on it so I'm marking as 
resolved. If you disagree, just let me know in the comments.

> @HttpCache(allow=true) not setting Cache-control, Pragma
> --------------------------------------------------------
>
>                 Key: STS-630
>                 URL: http://www.stripesframework.org/jira/browse/STS-630
>             Project: Stripes
>          Issue Type: Bug
>          Components: ActionBean Dispatching
>    Affects Versions: Release 1.5
>         Environment: Win64, Tomcat 6, IE/FF
>            Reporter: Matt Brock
>            Assignee: Ben Gunter
>            Priority: Minor
>
> The @HttpCache annotation isn't setting either the "Cache-control" or 
> "Pragma" headers.  In IE over SSL, this can potentially break file 
> downloading for StreamingResolutions.  In the following example, the action 
> is annotated to prevent caching, but the inner method overrides this to allow 
> it.
> ---
> @HttpCache(allow=false)
> public class MyUncachedAction implements ActionBean {
>   @DefaultHandler
>   public Resolution view() {
>     return new ForwardResolution("test.jsp");
>   }
>   @HttpCache(allow=true)
>   public Resolution download() {
>     return new StreamingResolution("application/vnd.mx-excel") {
>       public void stream(HttpServletResponse response) throws Exception {
>         // output response, e.g.:
>         // response.getOutputStream().write(...);
>         // response.getOutputStream().flush();
>       }
>     }.setFilename("test.csv");
>   }
> }
> ---
> The expiration header is properly set (line 87, 
> net.sourceforge.stripes.controller.HttpCacheInterceptor), but the 
> Cache-control and Pragma settings are left untouched, so you end up with a 
> mix of directives that, under *most* circumstances, will simply expire the 
> page, but in IE (because of the existence of the Cache-control/Pragma header) 
> will keep the no-cache setting, causing the download to fail.
> The fix I've been using is to add empty values to the appropriate headers.  
> E.g.-
> response.setHeader("Cache-control", "");
> response.setHeader("Pragma", "");
> More information on this can be found from Microsoft: 
> http://support.microsoft.com/kb/323308

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://www.stripesframework.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Stripes-development mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/stripes-development

Reply via email to