Changes between Version 9 and Version 10 of GZIPFilter
- Timestamp:
- 03/23/09 22:10:36 (16 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
GZIPFilter
v9 v10 27 27 28 28 == Motivations == 29 Compression of HTTP responses from GeoNetwork will speed up page refreshes and reduce the network footprint required to runGeoNetwork - see overview above.29 Compression of HTTP responses from !GeoNetwork will speed up page refreshes and reduce the network footprint required to run !GeoNetwork - see overview above. 30 30 31 31 == Proposal == … … 33 33 A GZIP compression filter has been written for general use by the people at jspbook.com - [http://www.onjava.com/pub/a/onjava/2003/11/19/filters.html Two servlet filters every web app should have] - this filter has been adapted for use in GeoNetwork and some issues that caused trouble in Internet Exploder has been fixed. The filter will only be applied to requests that can accept gzip compression and to requests that are not asking for an image (trapped using suffixes) or for a resource such as a thumbnail or download file as all of these are almost always compressed anyway. 34 34 35 One other function that may prove to be useful has been added to the filter. This function sets the expiry date on certain types of content (javascript, css, locale images) into the far future. The idea here is that this content will not be downloaded each time a user returns to a previously loaded page - instead this content will be found either in the web browser or proxy cache. The down side with this feature (apart from whether it really saves all that much anyway) is that the URLs of the static content need to change (eg. by adding ?version=whatever to javascript tags) when a new version of GeoNetwork is released to avoid stale static content being retrieved from the cache. This is not implemented inGeoNetwork and whether it is worth it will depend upon further testing of the worth of this feature.35 One other function that may prove to be useful has been added to the filter. This function sets the expiry date on certain types of content (javascript, css, locale images) into the far future. The idea here is that this content will not be downloaded each time a user returns to a previously loaded page - instead this content will be found either in the web browser or proxy cache. The down side with this feature (apart from whether it really saves all that much anyway) is that the URLs of the static content need to change (eg. by adding ?version=whatever to javascript tags) when a new version of !GeoNetwork is released to avoid stale static content being retrieved from the cache. This is not implemented in !GeoNetwork and whether it is worth it will depend upon further testing of the worth of this feature. 36 36 37 37 Steps needed to insert compression filter in servlet path. This involves modifications to web/geonetwork/WEB-INF/web.xml and web/intermap/WEB-INF/web.xml as follows: