I'm assuming that all 125 locations are being looped. What about initially loading the page with a "processing" animated gif and a message that the information is being retrieved, while in the background you can loop through and every tenth iteration use Sleep(1000) to delay the next ten?
Just my $0.03472 worth.
Where is it documented that you can only request 10 markers per second? It's not unusual using the Maps API to create a map with hundreds of markers displayed simultaneously, without having to delay requests before loading them in batches of 10.
One reference is https://developers.google.com/maps/documentation/business/articles/usage_limits#limitexcee ded where a solution in Python is given to pause a loop if an
OVER_QUERY_LIMIT error is received. I agree that there are maps out there with hundreds of markers. My mission is figuring how they are doing this.
That error shouldn't be caused simply by trying to display 125 markers at once on a map. Unless you're repeating this request a lot you shouldn't go over any usage limit. Just loop 1..125 adding a marker each time.
I got it to work using an array. But a recordset would eliminate future maintenance on my part. Thanks!
Director of Business Administration
Can you share how you did this, I'm having the same issue.
I believe that folks that are able to display hundreds of markers at once, without an error message, have already geocoded their results. In my humble opinion, I believe Google is limiting the requests to protect against server strain (which wouldn't be effected by our sites alone, but by millions of sites requesting the geocodes regularly).
Personally, I've had a difficult time, due to my current lack of Coldfusion knowledge, knowing how to perform a geocoding procedure when the address is initially retrieved via the sign-up form. Ideally, this information should be retrieved then and then stored in the database, so the geocoordinates are stored on our server instead of requesting them from the Google API.
That said, my current solution would be to delay the loop every tenth instance, but I've not found documentation on how to pull this off. If someone where able to point me in the right direction, I believe this would solve our problem with the over_query_limit error message.