문제

I am trying to profile the queries in my Sinatra app, which uses the Sequel ORM and MySql, through the mysql2 adapter. I'm using Rack::MiniProfiler, and the profiler seems to be working except it is not showing any queries, even though there are many of them being run on the page in question.

To use miniprofiler, all I have done is require 'rack-mini-profiler' and use Rack::MiniProfiler.

Am I missing some needed configuration to ensure the Sequel queries are picked up?

Here's a screenshot of miniprofiler's output:

enter image description here

If this cannot be made to work, I am also open to other suggestions to solve the query profiling problem, though I have tried Rack::Bug as well, and it too failed to pick up the Sequel queries.

도움이 되었습니까?

해결책

Make sure to require 'sequel' before require 'rack-mini-profiler'.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top