Ransack should explicitly support Rails connection adapters, and these should be documented and supported with specs / CI.
Rails 7.1+ / 8.x
postgresql in active_record/connection_adapters/postgresql_adapter.rb
mysql2 in active_record/connection_adapters/mysql2_adapter.rb
trilogy in active_record/connection_adapters/trilogy_adapter.rb, uses mysql as the backend
sqlite3in active_record/connection_adapters/sqlite3_adapter.rb
Third-Party Extensions
These are not supported by the Ransack gem explicitly but are known to be generally compatible. Enhancements to Ransack to support these should be generalisable or else applied in the adapter gem.
Support for PostGIS
As noted in this open issue features from PostGIS are not supported, but it has been added to the codebase and CI as if the activerecord-postgis-adapter gem is added to a project, it overrides the extension name to PostGIS.
Some options are to change the else clause in this code to default to Postgres (hacky) or better to explicitly add all supported connection adapters by name and then allow an override with a Ransack config setting (preferred).
Ransack should explicitly support Rails connection adapters, and these should be documented and supported with specs / CI.
Rails 7.1+ / 8.x
postgresqlin active_record/connection_adapters/postgresql_adapter.rbmysql2in active_record/connection_adapters/mysql2_adapter.rbtrilogyin active_record/connection_adapters/trilogy_adapter.rb, uses mysql as the backendsqlite3in active_record/connection_adapters/sqlite3_adapter.rbThird-Party Extensions
These are not supported by the Ransack gem explicitly but are known to be generally compatible. Enhancements to Ransack to support these should be generalisable or else applied in the adapter gem.
oracle_enhancedprovided by the activerecord-oracle_enhanced-adapter gem.sqlserverprovided by the activerecord-sqlserver-adapter gem.Support for PostGIS
As noted in this open issue features from PostGIS are not supported, but it has been added to the codebase and CI as if the activerecord-postgis-adapter gem is added to a project, it overrides the extension name to
PostGIS.Some options are to change the
elseclause in this code to default to Postgres (hacky) or better to explicitly add all supported connection adapters by name and then allow an override with a Ransack config setting (preferred).