Fix calculation of Active Record :db_runtime metric

This commit is contained in:
fatkodima 2023-12-30 23:55:44 +02:00
parent 0fb5f67ac4
commit 4f039d0328
1 changed files with 1 additions and 1 deletions

View File

@ -25,5 +25,5 @@ module ActiveRecord
end
ActiveSupport::Notifications.monotonic_subscribe("sql.active_record") do |name, start, finish, id, payload|
ActiveRecord::RuntimeRegistry.sql_runtime += (finish - start) * 1_000.0
ActiveRecord::RuntimeRegistry.sql_runtime += (finish - start)
end