0
votes

I have implemented an application which can import a GPX file and it contains many lat/long coordinates (several hundred).

My application performs a reverse geocoding for each lat/long. I want to display in a tableview all lat/long with their address (which will be ordered by country and town).

I'm performing only one geocoding request at a time (like it's described in Apple's documentation of reverseGeocodeLocation() in Core Location. When I get the answer of a geocoding request then I request the next one and then until I have resolved all my Lat/Long.

Unfortunately when I have resolved around 40 Lat/Long, the reverseGeocodeLocation() raises an error (CLError.network) and then I need to wait 60 seconds before the resolve the next ones etc...

I have several questions: - Is there a way to go faster? because if I have 800 lat/long it will takes around 20 minutes (800/40) * 60 = 1200 seconds (it's very long for an App running on a iPhone) - Even if I don't perform improvements on the rate, is there a risk that if I have many users then Apple will forbid my App because the number of Geocoding request will be too high?

Thanks for your feedback Regards,

Sebastien

1
The docs say "Send at most one geocoding request for any one user action". So I would say sending 800 requests for a single user action definitely runs the risk of you getting rejected for abusing the geocoding APIs. - dan
I agree but do you see others options (free)? - sebastien
did you find the solution? - Gringo Russo

1 Answers

0
votes

Is the GPX file static or will it be changing for every user/download? If static, then maybe just reverse geocode all the coords beforehand?

Alternately, look for a different service to do reverse geocoding.