aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib
diff options
context:
space:
mode:
authorXavier Noria <fxn@hashref.com>2013-05-10 08:05:54 -0700
committerXavier Noria <fxn@hashref.com>2013-05-10 08:05:54 -0700
commit4fa860728fe2ed8f248e9f3e89f0a144b8f314c8 (patch)
tree1db73184fbd993810887808f2a88c2c27915d4cd /activerecord/lib
parent3589181122f1a70abc1acd8c6bf41b46e2be2f5a (diff)
parenta33d320cf4b57fabd9c299b09c217ee3955ecc77 (diff)
downloadrails-4fa860728fe2ed8f248e9f3e89f0a144b8f314c8.tar.gz
rails-4fa860728fe2ed8f248e9f3e89f0a144b8f314c8.tar.bz2
rails-4fa860728fe2ed8f248e9f3e89f0a144b8f314c8.zip
Merge pull request #10555 from dasch/dasch/3-2-stable
Don't try to EXPLAIN select_db calls
Diffstat (limited to 'activerecord/lib')
-rw-r--r--activerecord/lib/active_record/explain_subscriber.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/activerecord/lib/active_record/explain_subscriber.rb b/activerecord/lib/active_record/explain_subscriber.rb
index 859c8edfc5..1d861a57db 100644
--- a/activerecord/lib/active_record/explain_subscriber.rb
+++ b/activerecord/lib/active_record/explain_subscriber.rb
@@ -15,7 +15,7 @@ module ActiveRecord
# On the other hand, we want to monitor the performance of our real database
# queries, not the performance of the access to the query cache.
IGNORED_PAYLOADS = %w(SCHEMA EXPLAIN CACHE)
- EXPLAINED_SQLS = /\A\s*(select|update|delete|insert)/i
+ EXPLAINED_SQLS = /\A\s*(select|update|delete|insert)\b/i
def ignore_payload?(payload)
payload[:exception] || IGNORED_PAYLOADS.include?(payload[:name]) || payload[:sql] !~ EXPLAINED_SQLS
end