Commit 093789d4 authored by charlie ablett's avatar charlie ablett

Merge branch 'ajk-query-recorder' into 'master'

Make debug logs more greppable

See merge request gitlab-org/gitlab!31557
parents b797bbe6 58351728
...@@ -19,7 +19,9 @@ module ActiveRecord ...@@ -19,7 +19,9 @@ module ActiveRecord
def show_backtrace(values) def show_backtrace(values)
Rails.logger.debug("QueryRecorder SQL: #{values[:sql]}") Rails.logger.debug("QueryRecorder SQL: #{values[:sql]}")
Gitlab::BacktraceCleaner.clean_backtrace(caller).each { |line| Rails.logger.debug(" --> #{line}") } Gitlab::BacktraceCleaner.clean_backtrace(caller).each do |line|
Rails.logger.debug("QueryRecorder backtrace: --> #{line}")
end
end end
def get_sql_source(sql) def get_sql_source(sql)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment