A gem to spy queries running with Active Record and report missing indexes

Imagine you have an application running in production and after a deploy, it starts to slow down.After a perhaps exhaustive debugging session, you may find that a new query or perhaps a change in the database schema was responsible for starting to have queries that do not use database indexes.Then, you create the appropriate index and the problem is solved!By using this gem, you can get those queries that are not using suitable database indexes in your test suite. So you won't have surprises like the example above, after a deploy.You can also enable the gem in your development/staging environment, generate a report and analyze if there is any missing index.
A gem to spy queries running with Active Record and report missing indexes #ruby #rubydeveloper #rubyonrails #active #gem #record https://rubyonrails.ba/single/a-gem-to-spy-queries-running-with-active-record-and-report-missing-indexes

Nezir Zahirovic

Contractor Ruby On Rails (8+ years) / MCPD .Net / C# / Asp.Net / CSS / SQL / (11 years)

related articles