[OpenLayers-Users] Advice about Google layer limitations

Adrian Popa adrian_gh.popa at romtelecom.ro
Fri Nov 27 02:18:34 EST 2009


Hello everybody,

I would  like to share with you my findings about the usage of Google 
background on very large maps. I have to render a map with the screen 
resolution of about 4500x3100 (on a wall of screens). It works ok with 
WFS layers, OSM and even Microsoft Virtual Earth, but I have issues with 
Google and Yahoo.

When I switch to the google layer, the background turns gray and then 
the browser starts loading the images. After about 130s of loading 
(there are quite a lot of pictures), I notice that google starts 
throwing back HTTP 403 errors (Resource temporary unavailable). Just 
before seeing these errors, some images (the center part of the map) 
start appearing, but only about 1/4 of the map is drawn. If I wait about 
5 minutes, the download process gives up (it still receives HTTP 403 
errors all this time), but it displays the rest of the images - which 
were apparently downloaded before the 403 error appeard.

I'm thinking it manages to download most of the visible images + some 
images in the bbox (which is quite large), but not all the images before 
getting errors. The problem is the Google API doesn't display what it 
downloaded, but waits for more images to be downloaded.

After analysing the data, I noticed that when the first DNS query is 
done for the Google cache, it receives back 4 IP addresses. However, 
only the first 2 IPs are used for traffic - and these 2 IPs start 
sending back HTTP 403 errors after a while.

I would like to know if the following are possible:
1. configure the Google API to use all the IP addresses it receives in 
the DNS query - maybe this avoids the 403 erros
2. configure the Google API to display the pictures received without 
waiting for more pictures to download. I'm not sure if this is possible 
- maybe the images are pipelined through the same connection - and they 
are shown only when the connection closes.
3. reduce the bbox for the Google Layer - this should be fine for my 
needs - and maybe avoids the 403 errors.

With regard to the Yahoo layer - things are better. It loads faster for 
the same size (they don't seem to have a "throttling" mechanism), but it 
only displays the final image when all the bits are downloaded - so it's 
as fast as the slowest image. Can this behavoir be changed from within 
OpenLayers?

Thanks,
Adrian




More information about the Users mailing list