[Opensymphony-oscache] Re: Got "HTTP/1.1 304 Not Modified" When Press Ctrl + F5
Deep Blue <[email protected]> Tue, 05 Dec 2006 16:57:08 CST
| Newsgroups | gmane.comp.java.open-symphony.os-cache |
|---|---|
| Message-ID | <16049594.1165359563831.JavaMail.os-j2ee@opensymphony01.managed.contegix.com> |
Usually "Cache-control : no-cache" is sent by [b]server to browser[/b] to ask browser not to cache the content. When we do hard-refresh, "Cache-control : no-cache" is sent by [b]browser to server[/b] to ask server not to send back the 'cache' copy. Anyway I tested with the following parameters: <filter> <filter-name>CacheFilter</filter-name> <filter-class>com.opensymphony.oscache.web.filter.CacheFilter</filter-class> <init-param> <param-name>time</param-name> <param-value>600</param-value> </init-param> <init-param> <param-name>scope</param-name> <param-value>application</param-value> </init-param> </filter> <filter-mapping> <filter-name>CacheFilter</filter-name> <url-pattern>/getThumbnail.do</url-pattern> </filter-mapping> The browser still send "Cache-control : no-cache" in the header when I do hard-refresh. When I do hard-refresh, this "Cache-control : no-cache" appears in all the http header, including static image, jsp, which are not under oscache. "cache-control : no-cache" doesn't appear in http header [b]from browser unless we do a hard-refresh.[/b] I will dig out the HTTP protocol spec and check out about the hard-refresh later. Thanks! --------------------------------------------------------------------- Posted via Jive Forums http://forums.opensymphony.com/thread.jspa?threadID=52057&messageID=105406#105406