Maybe you want to read
Getting Started with Geocoding in Rails – Part 1
July 12, 2016
Rewrite vs. Refactor: The limits of one against the other.
February 16, 2017