Skip to content Skip to sidebar Skip to footer

Google Maps Geocoding Api V3 Search Ok With Wifi But Responses Over_query_limit With Data Connection

My Google Maps activity searches for addresses with Google Maps Geocoding API V3. I see that sometimes, even if I repeat the search multiple times in sequence, Google Maps response

Solution 1:

Your problem most probably resides in your mobile operator. The vast majority of operators use a technique called NAT overloading and assign the same external IP to a number of devices. If your operator assigns a very large number of devices to a single IP and a number of them uses similar services, everyone will have a problem, as all requests will appear to stem from the same IP.

Your success with the 10*200ms requeries seems to be connected with the expiration of the OVER_QUERY_LIMIT flag from the server-side, as it is implied in this(Usage Limits for Google Maps API Web Services) document, which suggests that upon receiving this status, you should requery after 2secs to see if you exceeded your daily usage or you sent too many requests.

This does not occur through wifi as your phone has its own, more-or-less unique IP.

Solution 2:

I found a workaround that often (not always) solves the problem: requerying Google every 200 ms if I get OVER_QUERY_LIMIT, for a maximum of 10 times.

Post a Comment for "Google Maps Geocoding Api V3 Search Ok With Wifi But Responses Over_query_limit With Data Connection"