I want to speed up my web application which is in java and am also using ajax, javascript. can someone explain through an example to how to implement image caching.I am using IBM Webspere
Asked
Active
Viewed 104 times
-3
-
1http://stackoverflow.com/questions/2872613/caching-images-served-by-servlet – Suresh Atta Aug 12 '15 at 08:58
-
Isn't that usually done by the browsers? By default, every browser will cache the images, css, js files and you should not be worried about controlling those caching in server side.. – The Coder Aug 12 '15 at 09:04
1 Answers
0
Ideally static content is cached by browser at client side but in order to reduce load on application server you can use HTTP server like Apache or IBM in between your client(browser, mobile ...) and application server. You can search Use HTTP server to cache static content

Ganesh Pol
- 413
- 1
- 8
- 29
-
That is what I want to know where can I put Expires and max-age for cahe-control of images. Please elucidate on this – Abhi Aug 12 '15 at 09:29
-
Hi Abhi, Thumb rule for improving performance of system is to make system work on less data. although i had not used expires, max-age, cache control ... but keeping http server in between your application server and client will improve page loading time to much huge extent. i had seen it improves 40 to 70% – Ganesh Pol Aug 12 '15 at 09:33