Skip to content
Browse files

query cache instrumentation should included the bindings in the paylo…

…ad [closes #4750]
  • Loading branch information...
1 parent 7619bcf commit de161003c36a0cd967aa393e7706b12055770174 @fxn fxn committed
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/lib/active_record/connection_adapters/abstract/query_cache.rb
View
2 activerecord/lib/active_record/connection_adapters/abstract/query_cache.rb
@@ -69,7 +69,7 @@ def cache_sql(sql, binds)
result =
if @query_cache[sql].key?(binds)
ActiveSupport::Notifications.instrument("sql.active_record",
- :sql => sql, :name => "CACHE", :connection_id => object_id)
+ :sql => sql, :binds => binds, :name => "CACHE", :connection_id => object_id)
@query_cache[sql][binds]
else
@query_cache[sql][binds] = yield

0 comments on commit de16100

Please sign in to comment.
Something went wrong with that request. Please try again.