I’m about to add geocoding to not one, but 2 apps. We have the liberty of picking the currently best available solution. We deploy on Heroku. We want to do real estate mapping type operations, such as show records within N miles.
Any suggestions or favorites?
List here: https://www.ruby-toolbox.com/categories/geocoding___maps
Useful slide deck: Geolocation on Rails
I’ve been using geokit-rails for about a year in production with zero problems. It integrates nicely with Rails, and is fairly quick to implement and use.
One of my use cases:
- Model that contains addresses of shipping points
- One search field that accepts a street address, zipcode, state, or city, or all 4
- Returns shipping address points from the model that are within in X miles of the search param, sorted by distance closest to search param
I’ve recently used activerecord-postgres-earthdistance because it uses earth_distance functions from postgres, that performs faster when querying lots of records by distance, but it doesn’t have the geocoding feature (convert an address from string to lat/lon).
Geokit and GeoCoder seems to be good solutions. easy to use and complete (both can geocode data, calculate distance between points, and query the database). Geokit seems to be lightweight.
RGeo is too complex, it is recommended for gis apps, where you need to map various shapes of geographical data, like lines/areas/neighborhoods.
I love Geocoder, I’ve used it in few projects. They have pretty good public interface and strong community as well.
I’m looking to track GPS locations that I enter. Does anyone know if these gems are set up to search for nearby locations I add to my database? These locations are not street addresses, just points on a map.