Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How long does Google Maps cache kml files?

I have over 20 kml/kmz files that I let users add to a Google Maps (ver 2). I know that if I modify the kml file, Google has it cached and won't update it immediately unless you change the file's name.

How long will it be before Google Maps updates its cache?

If it updates its cache within a month, then for minor changes to my KML files I can avoid updating my file names.

like image 665
Aaron Kreider Avatar asked Feb 02 '23 15:02

Aaron Kreider


1 Answers

See here: http://code.google.com/apis/kml/documentation/kmlelementsinmaps.html

Expiration and time-based refresh are generally supported, although Google Maps does not refetch content from the Internet more often than (in the order of) fractions of a minute to a few minutes. Google Maps ignores expiration settings in the HTTP headers but does use the expiration settings specified in KML. In the absence of expiration settings, or within the time validity interval, Google Maps may cache data fetched from the Internet for unspecified durations. A refetch of the data from the Internet can be forced by renaming the document and fetching it under a different URL, or by making sure that the document contains appropriate expiration settings.

Basically they don't specify an exact time for the duration of their cache. However I believe from experience that it is in the order of minutes and not months.

like image 83
supakeen Avatar answered Feb 13 '23 02:02

supakeen