ankane / distribute_reads

Scale database reads to replicas in Rails

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Postgis adaptor missing?

madisonsites opened this issue · comments

Salutations!

I'm getting an error when attempting to run my app that seems to imply that the adaptor for postgis is missing:

Could not load 'active_record/connection_adapters/postgis_makara_adapter'

Is something wrong with my setup?

staging:
  url: postgis-makara:///
  makara:
    sticky: true
    connections:
      - role: master
        name: primary
        url: <%= ENV.fetch('DATABASE_URL', '').sub(/^postgres/, "postgis") %>
      - name: replica
        url: <%= ENV.fetch('REPLICA_DATABASE_URL', '').sub(/^postgres/, "postgis") %>
    encoding: unicode
    pool: 5
    schema_search_path: public

Hey @madisonsites, try makara-postgis:/// (it looks like Makara accepts either order for Postgres but only one for PostGIS: https://github.com/instacart/makara/tree/master/lib/active_record/connection_adapters)

That worked, thank you @ankane !