0 Replies Latest reply: May 4, 2012 5:44 AM by Ivan Ravin RSS

client cache deterioration after migration 3.x -> 4.x

Ivan Ravin Newbie

Richfaces 3.x used own mechanism of resource caching, and all static RF3.x resources had 24hours cache. By default they come with headers like this:

Cache-Control     max-age=86400

 

New 4.x richfaces  send some resources with own mechanism (...rfRes/calendar.ecss.xhtml?db=eAG7mShzEgAFjAIg&ln=org.richfaces), and some - as new JSF2 resources (...javax.faces.resource/calendar.js.xhtml?ln=org.richfaces). In addition, a4j:loadStyle and a4j:loadScript tags was excluded, because JSF2 has own h:outputScript and h:outputStylesheet, wich can load resources too.

But this new JSF2 resources dont have cache headers, so on every page render browser sends request and receive response "304 Not Modified".

Is it possible to exclude this requests (add cache headers) for static RF resources?

Does new h:outputScript and h:outputStylesheet tags recognize static resources?