How to execute asynchronous requests on rails?

I want to get geocoding api to get latitude and longitude for a given address, but there is > so I created several gmail accounts to access the geocoding API with multiple API keys so that I can access the API without the OVER_QUERY_LIMIT problem

  • How to repeat these API keys to get latitude and longitude using sidekiq?
  • Is there a better way to achieve the above without using sidekiq
+4
source share
2 answers

You can record requests at your end with a variable and switch between API credentials when you run out of limit. You can also do some caching to reduce these API calls.

0
source

It depends on what you are trying to achieve.

If you have a large consumer application with a large number of geocoding requests, I would recommend that you use client-side geocoding. Google provides the Javascript SDK . You will still have a restriction on request, but you will transfer it to your customers. Thus, each client will have its own limit. Thus, you are unlikely to exceed this limit. Large sites such as Foursquare also do this.

, - , . . Google . . , .

Google, . Google . , . - !! 500 Internal server error.

, !

:)

0

Source: https://habr.com/ru/post/1620705/


All Articles