java - Caching in Tomcat and Spring MVC -


i have web application gets deployed war file tomcat container. application has 2 main aspects:

  1. it uses spring mvc provide rest endpoints
  2. it ships angularjs based single page application static content. technically there index.html in root webapp folder uses html http-equiv="refresh" redirect redirect actual index.html in subfolder.

when update application notice browser not load latest version server , shows older cached version. example website shows current version number on login page, if update 1.0.5 1.0.6, find browser still shows 1.0.5 if reload page. pressing ctrl+f5 ignore cache solves temporarily.

i not familiar whole caching topic, looking resources started.

questions:

  • is caching problem must configure in spring?
  • is rather must configured in tomcat when deploy war file?
  • is possible problem caused html redirect mentioned above?

these tags should prevent reading cache

<meta http-equiv="pragma" content="no-cache">  <meta http-equiv="cache-control" content="no-cache">  <meta http-equiv="expires" content="sat, 01 dec 2001 00:00:00 gmt"> 

the cache-control header added in http 1.1, while other 2 present in http 1.0.


Comments

Popular posts from this blog

sql - invalid in the select list because it is not contained in either an aggregate function -

Angularjs unit testing - ng-disabled not working when adding text to textarea -

How to start daemon on android by adb -