GWT*nocache*并在Jetty 7中部署应用程序
在中,要像这样放置一个*.htaccess配置文件,以避免缓存主javascript gwt应用程序GWT*nocache*并在Jetty 7中部署应用程序,gwt,jetty,no-cache,Gwt,Jetty,No Cache,在中,要像这样放置一个*.htaccess配置文件,以避免缓存主javascript gwt应用程序 <Files *.nocache.*> ExpiresActive on ExpiresDefault "now" Header merge Cache-Control "public, max-age=0, must-revalidate" </Files> <Files *.cache.*> ExpiresActive on Expi
<Files *.nocache.*>
ExpiresActive on
ExpiresDefault "now"
Header merge Cache-Control "public, max-age=0, must-revalidate"
</Files>
<Files *.cache.*>
ExpiresActive on
ExpiresDefault "now plus 1 year"
</Files>
过期于
ExpiresDefault“立即”到期
标头合并缓存控制“公共,最大年龄=0,必须重新验证”
过期于
ExpiresDefault“现在加上1年”
有没有办法对Jetty进行同样的操作?(不需要使用httpd jetty模块)此答案显示了如何禁用/启用jetty提供的所有文件的缓存: 我认为,要为单个文件(例如nocache)设置自定义缓存设置,必须使用过滤器,并在HttpResponseObject中为与请求URI匹配的文件手动设置头,如下所述: